• Welcome to the Chevereto User Community!

    Here, users from all over the world come together to learn, share, and collaborate on everything related to Chevereto. It's a place to exchange ideas, ask questions, and help improve the software.

    Please keep in mind:

    • This community is user-driven. Always be polite and respectful to others.
    • Support development by purchasing a Chevereto license, which also gives you priority support.
    • Go further by joining the Community Subscription for even faster response times and to help sustain this space

BBCode help ?

Status
Not open for further replies.

Resul

Chevereto Member
I have a problem if i can say is problem.

I always use BBCode: and i share in forums but in 2.0 script you changed something that in 1.9 was better than 2.0 im saying for this links down.
I will give two examples from 1.9 and 2.0

In 2.0

In 1.9

I think you know this better than me but can you help me i want to edit this so can you help me i want always BBCode to be like in 1.9 so please can you do this for me.
 
For what I can tell you want the link to point ?v= instead of the direct file right?
 
Rodolfo said:
For what I can tell you want the link to point ?v= instead of the direct file right?

I want when someone click on pic with BBCode to go to my index site and where i will have advertising and to win some buck$.
 
If you want to change all the direct links to viewer then do the following:

1. Do this: http://chevereto.com/forums/post5295.html#p5295

2. Open content/system/js/peafowl.php and change this:
Code:
/*** Process the ImagesObj ***/
var multiupload_thumbs = "";
$.each(ImagesObj, function(key, value) {
    multiupload_thumbs += '<img src="'+value.thumb_url+'" id="'+key+'" height="'+value.thumb_height+'"/>';
    multi_codes_textarea["direct-links"] += value.img_url+"\n";
    multi_codes_textarea["html-codes"] += '&lt;img src="'+value.img_url+'" border="0" /&gt;'+"\n";
    multi_codes_textarea["bb-codes"] += "[img]"+value.img_url+"[/img]"+"\n";
    multi_codes_textarea["html-thumb-codes"] += '&lt;a href="'+value.img_url+'"&gt;&lt;img src="'+value.thumb_url+'" border="0" /&gt;&lt;/a&gt;'+"\n";
    multi_codes_textarea["thumb-bb-codes"] += "[url="+value.img_url+"][img]"+value.thumb_url+"[/img][/url]"+"\n";
});

To this:
Code:
/*** Process the ImagesObj ***/
var multiupload_thumbs = "";
$.each(ImagesObj, function(key, value) {
    multiupload_thumbs += '<img src="'+value.thumb_url+'" id="'+key+'" height="'+value.thumb_height+'"/>';
    multi_codes_textarea["direct-links"] += value.img_url+"\n";
    multi_codes_textarea["html-codes"] += '&lt;img src="'+value.img_url+'" border="0" /&gt;'+"\n";
    multi_codes_textarea["bb-codes"] += "[img]"+value.img_url+"[/img]"+"\n";
    multi_codes_textarea["html-thumb-codes"] += '&lt;a href="<?php echo __CHV_BASE_URL__; ?>?v='+value.img_name+'" &gt;&lt;img src="'+value.thumb_url+'" border="0" /&gt;&lt;/a&gt;'+"\n";
    multi_codes_textarea["thumb-bb-codes"] += "[url=<?php echo __CHV_BASE_URL__; ?>?v="+value.img_name+"][img]"+value.thumb_url+"[/img][/url]"+"\n";
});
 
Same...


I want to do like this


When someone click to go to my index of site do you understand me.
Thanks
 
You need to actually do this: http://chevereto.com/forums/post5295.html#p5295 (it seems that you skip this part)

Open: /includes/template.functions.php

Replace this:
Code:
return htmlentities('[url='.get_img_url().'][img]'.get_thumb_url().'[/img][/url]');

With:
Code:
return htmlentities('[url='.get_img_viewer().'][img]'.get_thumb_url().'[/img][/url]');

Also notice that multiupload isn't working on your server. Most likely a session issue.
 
Yeah man thnx for this help now works fine.

But look at www.hostyourpic.com and try to uploud more than 1 photo and you can get just 1 link not like in normal site you get for each photo you uploud and i dont know where is problem.
Can you do anything about this ?
 
Add that at the bottom of includes/config.php file before the ?> code
 
Ok, the issue was a wrong code in your JS. Please keep in mind that the support is just for programing errors and not bad editing.

Btw, I will remake the functions (php and js) in order to easy switch between viewer and direct link.

Regards.
 
Thanks Rodollfo, I got it to work. I have one more question though, is it possible to make all links direct to the viewer page? This is including direct image links.

For example if I type in http://www.mysite.com/images/abc.jpg in a browser it will redirect me to the viewer page of that image instead of the direct image.

Thanks again!
 
Yes, using .htaccess can be done. but please open a new topic for that.
Thanks.
 
Status
Not open for further replies.
Back
Top