4images Forum & Community
Welcome, Guest. Please login or register.
Did you miss your activation email?
September 02, 2014, 01:33:26 PM

Login with username, password and session length
Search:     Advanced search
Togle to toolbar
Translate this page with =>
Translate this page >
* Home Help Search Login Register
 
+  4images Forum & Community
|-+  4images Modifications / Modifikationen
| |-+  Mods & Plugins (Requests & Discussions) (Moderators: mawenzi, Rembrandt)
| | |-+  [Mod] Show original image in new window by clicking on button
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Print
Author Topic: [Mod] Show original image in new window by clicking on button  (Read 5945 times)
lukasinoooo
Newbie
*
Offline Offline

Posts: 32

Thank You
-Given: 0
-Receive: 0


View Profile
« on: May 19, 2006, 01:08:15 AM »

Ok let's tray (my in english is  Rolling Eyes no comment) his MOD will let in detail page by clicking on the button, open new fullscreen window with bigger size image  Cool
demo: http://aletapety.pl/img-aaliyah-621-aaliyah3800x600-17464.htm click on the in page

Step 1
Download file from the attachment ,place in your catalogue frompictures (/images)



1. open /includes/functions.php file
1.1. Find:

"image_id" => $image_row['image_id'],

Replace with:

"image_id" => $image_row['image_id'],
"download_full" => $download_full,


1.2. Find:

    $download_button = "<img src=\"".get_gallery_image("download_off.gif")."\" border=\"0\" alt=\"\" />";

Replace with:

    $download_button = "<img src=\"".get_gallery_image("download_off.gif")."\" border=\"0\" alt=\"\" />";
    $download_full = "<img onClick=\"window.open('" . substr(MEDIA_PATH,2) . "/" . $image_row['cat_id'] . "/" . $image_row['image_media_file'] ."','new','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,copyhistory=no,width=800,height=600,top=50,left=50')\" src=\"".get_gallery_image("full.gif")."\" border=\"0\" alt=\"\" />";


1.3. Find:

    $download_button = "<a href=\"".$site_sess->url(ROOT_PATH."download.php?".URL_IMAGE_ID."=".$image_row['image_id'])."\"".$target."><img src=\"".get_gallery_image("download.gif")."\" border=\"0\" alt=\"\" /></a>";

Replace with:


    $download_button = "<a href=\"".$site_sess->url(ROOT_PATH."download.php?".URL_IMAGE_ID."=".$image_row['image_id'])."\"".$target."><img src=\"".get_gallery_image("download.gif")."\" border=\"0\" alt=\"\" /></a>";
    $download_full = "<img onClick=\"window.open('" . substr(MEDIA_PATH,2) . "/" . $image_row['cat_id'] . "/" . $image_row['image_media_file'] ."','new','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=no,copyhistory=no,width=800,height=600,top=50,left=50')\" src=\"".get_gallery_image("full.gif")."\" border=\"0\" alt=\"\" />";




Now all you need is add {download_full} in details.html or if you want in thumbnail_bit.html  Wink

* full.gif (0.75 KB - downloaded 966 times.)
Logged
germish
Full Member
***
Offline Offline

Posts: 102

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #1 on: October 04, 2006, 03:48:14 PM »

I could have seen the point of this if there would be 3 different image sizes of a picture !!!
1. Thumbnail size = few KB
2. Enlargement size = KB according to size
3. Original size by click = KB size of the original photo.

YET this is NOT was is happening here.

2. and 3 are the same size in KB only displayed in different pixelsize.

So once you click on enlargement you already download the full picture size which is cropped back.
(If you right click and save this/edit on your PC you have the correct size anyway)

I fail to see the point of opening up the foto in another window, which by the way is not opening in fullscreen mode !!!

If you have a mod which actually would have a third REAL size which is saved with the DB record this would be far more helpful.
Logged

Best Regards
Ralf, the Island Ape !
cloe
Full Member
***
Offline Offline

Posts: 120

Thank You
-Given: 0
-Receive: 2


View Profile
« Reply #2 on: July 30, 2007, 12:55:20 AM »

This works... but there is something that im not happy with..
Is there a way to make the window thats pop up to be 100%. And display the pidture in the center horrisantly and vertically, with a black background.
And remove the code thats try to rezise the picture?
Logged

Peace And Luv Smile

--Cecilie--

http://www.cloevvold-photo.com
son_gokou
Full Member
***
Offline Offline

Posts: 189

Thank You
-Given: 2
-Receive: 1


View Profile
« Reply #3 on: August 08, 2007, 01:23:58 AM »

This is good... but what's the point of showing in a new window the same size image?
Logged
thunderstrike
4images Guru
*******
Offline Offline

Posts: 2327

Thank You
-Given: 0
-Receive: 10


View Profile
« Reply #4 on: August 08, 2007, 01:25:05 AM »

Just target _blank if use 100% image. Correct, no point with MOD.
Logged

8 steps need when ask question -

- PHP version (ACP - > phpinfo())
- mySQL version (ACP - > phpinfo())
- 4images version
- Post screenshot / URL
- Post code in BB Code (no need full file for code) or post attach file
- It doesn't work. What is say - what is do for no work
- Install MOD ? If so - please say (troubleshooting)
- Read FAQ ? Install Bug fixes ?
madynmalfi
Newbie
*
Offline Offline

Posts: 24

Thank You
-Given: 2
-Receive: 3


View Profile
« Reply #5 on: December 01, 2012, 06:57:22 AM »

i've seen many mods for this but each mode have some problems Very Happy ...
This might help you .. give it try ( i am sure its what you are looking for)..
This mod will let you make any size you want in the detail page but without resizing the picture + link or button to show full picture in new page..

demo: http://nice-cool-pics.com/img-aconcagua-hike%2C-argentina-4769.htm

lets start

step 1
open 4image/templates/your template/midia/jpg.html  
(i have just jpg in my site so i made changes in jpg) (if your images are all in jpg then chose jpg , if not then you have to change all the picture types you have)
Find
1
<img src="{media_src}" border="0" alt="{image_name}" width_height="" usemap="#navi" />
replace it with
1
<img src="{media_src}" border="0" alt="{image_name}" width="750" height="750" usemap="#navi" />
change width="750" and height="750" to your size that you want to show in detail page

step 2
open  4image/templates/your template/detail.php
add this in any place you want to show link to show the full size picture
1
<h2><a href="{media_src}">see fullsize</a></h2>

Logged
Pages: [1] Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.233 seconds with 22 queries.