Topic: default image html tag

Hi together,

i have a question about posting images.
is it possible to change the import html from

<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'><img border="0" align="none" alt="" src="http://mydomain/image.jpg"></div>

to

<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'><img border="0" width="650px" height="450px" alt="" src="http://mydomain/image.jpg"></div>

and if it is possible where can i change this?

thanks for your help


so long

Arge

2 (edited by 2012-06-04 19:47:28)

Re: default image html tag

Assuming that you are using the original images.mdu file in cutenews 1.4.7

Open inc/images.mdu,  find the insertion code then add in the paramenters that you want like this:

Find

$config_http_script_dir/data/upimages/" + selectedImage + "\" alt=\"" + alternativeText + "\" border=\"" + imageBorder + "\" align=\"" + imageAlign;

Replace with

$config_http_script_dir/data/upimages/" + selectedImage + "\" alt=\"" + alternativeText + "\" border=\"" + imageBorder + "\" width=\""+ 650 +"\" height=\""+ 450 +"\" align=\"" + imageAlign;

Edit: problem with posting this as the forum removes the escape codes!  follow the syntax in the original code for escaping the quotes when adding in the new parameters.

Re: default image html tag

Thank you for this quick answer.
I Just have an further question.
Could I also integrate as JS lightbox?

Re: default image html tag

I don't use Lightbox but I do use Highslide.
I am not familiar with lightbox syntax.
You should be able to add the code into inc/images.mdu
Find  $link1 = htmlspecialchars
and add in your code

//Else
else {
$link1 = htmlspecialchars('<a target="_blank" href="'.$config_http_script_dir.'/data/upimages/'.($folder == '' ? '' : $folder.'/').$file.'">');
}

and add in your script for lighbox

I use this for Highslide:

else {
$link1 = htmlspecialchars('<a id="thumb1" class="highslide" onclick="return hs.expand(this)" href="'.$config_http_script_dir.'/data/upimages/'.($folder == '' ? '' : 
$folder.'/').$file.'">');
}

Re: default image html tag

It Looks like highslide does the same that lightbox is doing.
Thank you for your quick and proffesional help.

Re: default image html tag

Damoor & Communty i am afraid i need your help again.
I can´t find the script you have postet in the inc/images.mdu for adding highslide into cutenews.
is ist possible that you post your complete image.mdu so that i can import it to mywebsite?

Argentum

Re: default image html tag

Damoor & Communty i am afraid i need your help again.
I can´t find the script you have postet in the inc/images.mdu for adding highslide into cutenews.
is ist possible that you post your complete image.mdu so that i can import it to mywebsite?

Argentum

Sorry that was my fault. I did not explain that  I am using the advanced images.mdu by FI-DD from here:
http://cutephp.com/forum/index.php?showtopic=12087
You should be able to make all the changes in that version.

Re: default image html tag

Ok i downloaded the image.mdu from the topic addet the Code you postet and copied highslide to my webspace but i does not work.
i´ve got a different window for inserting images but can´t insert from that.
i am affraid i need further advises.

Argentum

9 (edited by 2012-06-06 12:06:45)

Re: default image html tag

Ok i downloaded the image.mdu from the topic addet the Code you postet and copied highslide to my webspace but i does not work.
i´ve got a different window for inserting images but can´t insert from that.
i am affraid i need further advises.

Argentum


Have you uploaded the highslide folder with the javascript routines to your server? You also need the css and javascript in the page on which you are showing the news. The high slide forum will show you how to integrate highslide into your web pages. Highslide.com
Clicking on the insert thumbnail from the add image in cutenews will then add in a thumbnail which will expand with highslide when clicked on. If you need complete tutorial then it will take me a while to write. I will pm you a link to one of my sites to see how it works.

You will need to upload a new image so that the thumbnails are created.

(this forum does not like my iPad - I am having a problem sending the pm. I will try later.)

Re: default image html tag

Hi together,

i have a question about posting images.
is it possible to change the import html from

<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'><img border="0" align="none" alt="" src="http://mydomain/image.jpg"></div>

to

<div class='codetop'>CODE</div><div class='codemain' style='height:200px;white-space:pre;overflow:auto'><img border="0" width="650px" height="450px" alt="" src="http://mydomain/image.jpg"></div>

and if it is possible where can i change this?

thanks for your help


so long

Arge

OK, I'm using the latest version of cutenews.

Where can I find the file to edit the standard code for showing images in the news? There ist no folder "inc" and no file "images.mdu"