4images Forum & Community
Welcome, Guest. Please login or register.
Did you miss your activation email?
November 20, 2018, 10:17:52 PM

Login with username, password and session length
Search:     Advanced search
Check the new Tutorial subforum with helpfull guides and tutorials for modifications and tweaks.
Togle to toolbar
Translate this page with =>
Translate this page >
* Home Help Search Login Register
 
+  4images Forum & Community
|-+  4images Modifications / Modifikationen
| |-+  Mods & Plugins (Releases & Support) (Moderators: mawenzi, Rembrandt)
| | |-+  [MOD] TiltViewer for 4images
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] 2 3 4 5 » »» Print
Current Topic Rating: *****
Author Topic: [MOD] TiltViewer for 4images  (Read 75410 times)
mawenzi
Moderator
4images Guru
*****
Offline Offline

Posts: 4500

Thank You
-Given: 36
-Receive: 121


View Profile
« on: March 07, 2008, 02:51:44 PM »


What is TiltViewer ?
TiltViewer is a free, customizable 3D Flash image viewing application.
  • Click images to zoom-in, click again to zoom-out.
  • Click the background to zoom-out.
  • Click the 'reload' button (below the image grid) to load a new set of images.
  • Click the 'flip' button (bottom-right of a zoomed-in image) to see image details.

More informations here : http://www.airtightinteractive.com/projects/tiltviewer/


How can I show images from my 4images website with TiltViewer on a extra site ?

A demo with TiltViewer and random images from my 4images-Mount-Kilimanjaro-Gallery :  here
And now the installations instruction ...

1. Step

Download TiltViewer v1.3

2. Step

Rename the index.html from the download package to viewer.html ...
Find in viewer.html in section // XML GALLERY OPTIONS ...
1
fo.addVariable("xmlURL", "gallery.xml");
and replace it with ...
1
fo.addVariable("xmlURL", "tiltviewer.php");

In viewer.html in section // GENERAL OPTIONS ...
You can change the design options of the viewer to your needs or to your 4images webdesign ...

3. Step

Create a new file "tiltviewer.php" with the following content ...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<?php
/**************************************************************************
 *                                                                        *
 *    4images - A Web Based Image Gallery Management System               *
 *    ----------------------------------------------------------------    *
 *                                                                        *
 *             File: tiltviewer.php by mawenzi                            *
 *     File-Version: 1.0 - 26.02.2008                                     *
 *        Copyright: (C) 2002 Jan Sorgalla                                *
 *            Email: jan@4homepages.de                                    *
 *              Web: http://www.4homepages.de                             *
 *    Scriptversion: 1.7.x                                                *
 *                                                                        *
 *                                                                        *
 *************************************************************************/

define('GET_CACHES'1);
define('ROOT_PATH''./');
define('GET_USER_ONLINE'1);
include(
ROOT_PATH.'global.php');
require(
ROOT_PATH.'includes/sessions.php');
$user_access get_permission();

//--------------------------------------------
//-- Random Images - TiltViewer --------------
//--------------------------------------------
$sql "SELECT i.image_id, i.cat_id, i.user_id, i.image_name, i.image_description, i.image_date, i.image_active, i.image_media_file, c.cat_name".get_user_table_field(", u.""user_name")."
        FROM ("
.IMAGES_TABLE." i,  ".CATEGORIES_TABLE." c)
        LEFT JOIN "
.USERS_TABLE." u ON (".get_user_table_field("u.""user_id")." = i.user_id)
        WHERE i.image_active = 1 AND c.cat_id = i.cat_id AND i.cat_id IN ("
.get_auth_cat_sql("auth_viewcat").")
        ORDER BY RAND()
        LIMIT 0,90"
;
$result $site_db->query($sql);

  echo 
"<tiltviewergallery>";
  echo 
"<photos>";

  while (
$image_row $site_db->fetch_array($result)){ 

       echo 
"<photo imageurl=\"".ROOT_PATH."/data/media/".$image_row['cat_id']."/".$image_row['image_media_file']."\" linkurl=\"\">";
       echo 
"<title>".$image_row['image_name']."</title>";
       echo 
"<description>".$image_row['image_description']."</description>";
       echo 
"</photo>";

  } 
// end while
  
echo "</photos>";
  echo 
"</tiltviewergallery>";

//----- End Random Images -------------------
?>


This "tiltviewer.php" presented "Random Images" from your 4images website ...
You can customise this file to your needs to show ...
- Random images from certain categories of your website
- All new images of your website
- New images from certain categories of your website
- a.s.o.

4. Step

Now upload the following files to your 4images root folder ...
- TiltViewer.swf
- swfobjects.js
- viewer.html
- tiltviewer.php

5. Step

Use the following link in your 4images templates to show your TiltViewer ...
1
<a href="http://www.Your_Website.com/viewer.html" target="_blank">Random Images with TiltViewer</a>

6. Step

Ready ... and have fun with TiltViewer ...  Mr. Green ... also in Full Screen ... Shocked


« Last Edit: March 07, 2008, 05:21:19 PM by mawenzi » Logged

Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...
Alessio
Jr. Member
**
Offline Offline

Posts: 59

Thank You
-Given: 0
-Receive: 0


View Profile WWW
« Reply #1 on: March 07, 2008, 03:24:35 PM »

Thank you!!  Very Happy

I have installed the mod but it doesn't work, I can't see any images http://www.webax.it/top.html.
If I try to open http://www.webax.it/tiltviewer.php I get this error

Quote  [Expand]
Notice: Undefined variable: additional_sql in /mounted-storage/home28b/sub001/sc24851-FNHZ/www/tiltviewer.php on line 25
An unexpected error occured. Please try again later.

Do I have to modify something in tiltviewer.php? And how to customize it?
« Last Edit: March 07, 2008, 04:41:52 PM by Alessio » Logged

Alessio
my homepage: http://www.webax.it
Sun Zaza
Sr. Member
****
Offline Offline

Posts: 397

Thank You
-Given: 28
-Receive: 1


View Profile
« Reply #2 on: March 07, 2008, 03:52:14 PM »

Hi mawenzi, Nice work  Wink

But I get this error when I try to open the page viewer.html


1
2
3
4
5
6
7
8
An ActionScript error has occurred


TypeError: Error #1088: The markup in the document following the root element must be well-formed.
at data::XMLDataSource/::onGotXML()
at flash.events::EventDispatcher/flash.events:EventDispatcher::dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/flash.net:URLLoader::onComplete()

Do you have any Idea?
Logged
mawenzi
Moderator
4images Guru
*****
Offline Offline

Posts: 4500

Thank You
-Given: 36
-Receive: 121


View Profile
« Reply #3 on: March 07, 2008, 04:04:41 PM »

@ Alessio and cruxy

... I made some changes in tiltviewer.php ...
... please try the mod installation again ...

And how to customize it?

... e.g. here ...
1
2
ORDER BY RAND()
LIMIT 0,90";
to
1
2
ORDER BY i.image_date DESC
LIMIT 0,20";

for your 20 latest / newest images ...
Logged

Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...
mawenzi
Moderator
4images Guru
*****
Offline Offline

Posts: 4500

Thank You
-Given: 36
-Receive: 121


View Profile
« Reply #4 on: March 07, 2008, 04:14:47 PM »

@ Alessio

... perfect ...  Wink
Logged

Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...
Sun Zaza
Sr. Member
****
Offline Offline

Posts: 397

Thank You
-Given: 28
-Receive: 1


View Profile
« Reply #5 on: March 07, 2008, 04:16:45 PM »

Respect!!!  Good
Logged
mawenzi
Moderator
4images Guru
*****
Offline Offline

Posts: 4500

Thank You
-Given: 36
-Receive: 121


View Profile
« Reply #6 on: March 07, 2008, 04:22:44 PM »

@ cruxy 

... also perfect ...  Wink
Logged

Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...
KurtW
4images Guru
*******
Offline Offline

Posts: 2778

Thank You
-Given: 0
-Receive: 8


View Profile WWW
« Reply #7 on: March 07, 2008, 04:27:13 PM »

Einfach nur geil  Wink
Logged

mawenzi
Moderator
4images Guru
*****
Offline Offline

Posts: 4500

Thank You
-Given: 36
-Receive: 121


View Profile
« Reply #8 on: March 07, 2008, 04:32:32 PM »

@KurtW

...  Mr. Green ...

@all
... it seem that now the installation can made without any trouble ...
Logged

Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...
Alessio
Jr. Member
**
Offline Offline

Posts: 59

Thank You
-Given: 0
-Receive: 0


View Profile WWW
« Reply #9 on: March 07, 2008, 04:41:07 PM »

@ Alessio and cruxy

... I made some changes in tiltviewer.php ...
... please try the mod installation again ...

And how to customize it?

... e.g. here ...
1
2
ORDER BY RAND()
LIMIT 0,90";
to
1
2
ORDER BY i.image_date DESC
LIMIT 0,20";

for your 20 latest / newest images ...



You are the best!  Very Happy
Logged

Alessio
my homepage: http://www.webax.it
mawenzi
Moderator
4images Guru
*****
Offline Offline

Posts: 4500

Thank You
-Given: 36
-Receive: 121


View Profile
« Reply #10 on: March 07, 2008, 04:44:34 PM »

@Alessio

...  Embarassed ...
Logged

Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...
Nordlicht2001
Newbie
*
Offline Offline

Posts: 29

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #11 on: March 07, 2008, 05:01:00 PM »

Hello,

if I want to see all pictures of a certain categorie, how to customise the tiltviewer.php?

Thanks,
Rüdiger
Logged
TIMT
Hero Member
*****
Offline Offline

Posts: 505

Thank You
-Given: 0
-Receive: 0


View Profile
« Reply #12 on: March 07, 2008, 05:05:25 PM »

Hi mawenzi - Just fantastic - Well done!  Good

I'd like to implement a link "Back".
How and where can I do that?

Thanks!

TIMIT
Logged
kai
Administrator
Addicted member
*****
Offline Offline

Posts: 1405

Thank You
-Given: 66
-Receive: 200


View Profile WWW
« Reply #13 on: March 07, 2008, 05:14:07 PM »

Very good!
Logged


Your first three "must do" before you ask a question:
1. Forum rules
2. FAQ
3. Search
mawenzi
Moderator
4images Guru
*****
Offline Offline

Posts: 4500

Thank You
-Given: 36
-Receive: 121


View Profile
« Reply #14 on: March 07, 2008, 05:17:21 PM »

@Nordlicht2001
try this ...
1
2
WHERE i.image_active = 1 AND c.cat_id = i.cat_id AND i.cat_id IN (1, 2)
ORDER BY RAND()";

... all images from categories 1 and 2 ... as random images ...

@TIMT
1. ... thanks ...
2.1 ... implement your back link in top of "viewer.html" ...
2.2 ... or use a page with back link in top and a Iframe with "viewer.html" as content ...

@Kai
... thanks ...
Logged

Your first three "must do" before you ask a question ! ( © by V@no )
- please read the Forum Rules ...
- please study the FAQ ...
- please try to Search for your answer ...

You are on search for top 4images MOD's ?
- then please search here ... Mawenzi's Top 100+ MOD List (unsorted sorted) ...
Pages: [1] 2 3 4 5 » »» Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.052 seconds with 20 queries.