PhotoPost Photo Gallery Sales PhotoPost Sales Toll Free Phone Number
Mon-Fri 9am-4pm EST
  PhotoPost Photo Sharing Photo Gallery    Visualize community tm
| | | | | | | | |

Go Back   PhotoPost Community > PhotoPost Support > PhotoPost Pro Support Forums > Photopost Pro How Do I...?

Photopost Pro How Do I...? Wondering how to do things in PhotoPost?

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
Old February 3rd, 2006, 06:28 PM   #21 (permalink)
Junior Member
Verified Customer
 
Join Date: Jan 2006
Posts: 20
Chuck,
Ok say I make a html filed called test.html
I will stick in
Quote:
<?

echo <<<HTML

SOME GOES HERE

HTML;

include('../photoalbums/htdocs/inc_features.php');

echo "$photopostfeature";

echo <<<HTML

maybe some more html here

HTML;

?>
Now, it should work correct?
http://www.disneypost.com/test.html
I get nothing. Now my inc_features.php is located in photoalbums/htdocs/
disneypost is offline   Reply With Quote
Old February 3rd, 2006, 07:45 PM   #22 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 68,070
The file I noted above is a PHP file not an HTML FILE
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Old February 4th, 2006, 01:13 PM   #23 (permalink)
Junior Member
Verified Customer
 
Join Date: Jan 2006
Posts: 20
Ok, I created this file called test.php with Dreamweaver.
I included the code below. Why doesn't it work. Chuck, I am very frustrated to get this work. Thank you for your help.

Quote:
<?

echo <<<HTML

SOME GOES HERE

HTML;

include 'http://photoalbums.disneypost.com/inc_features.php';

echo "$photopostfeature";

echo <<<HTML

maybe some more html here

HTML;

?>
disneypost is offline   Reply With Quote
Old February 4th, 2006, 02:02 PM   #24 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 68,070
include is a server path not html and it would be like this

include('../photoalbums/htdocs/inc_features.php');

make sure to put the proper server path there and then post a link to test.php
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Old February 6th, 2006, 11:33 AM   #25 (permalink)
Member
Verified Customer
 
Join Date: Jun 2005
Posts: 34
Quote:
Originally Posted by Chuck S
thirtytwo You can edit inc_features.php directly if not using it elsewhere. Otherwise a copy is fine as long as you place the proper path to config-int.php in there.
Thanks, man! I duplicated inc_features.php and am calling it out. But the PHP page (outside of Vb or PP) where I'm calling it out is throwing up three errors from the inc_features.php page I'm using. And I edited the inc_features.php page as you suggested.

Errors:
Quote:
Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home/dirtragm/public_html/gal/inc_features2.php on line 49

Warning: mysql_free_result(): supplied argument is not a valid MySQL result resource in /home/dirtragm/public_html/gal/inc_features2.php on line 63

Warning: mysql_fetch_row(): supplied argument is not a valid MySQL result resource in /home/dirtragm/public_html/gal/inc_features2.php on line 115
I can't seem to ID what the problem is in those lines. Thanks!
thirtytwo16 is offline   Reply With Quote
Old February 6th, 2006, 02:25 PM   #26 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 68,070
Well make sure if your trying to access a database in some non database program you uncomment the $link and mysql_select_db lines at the top of the file and put the proper database info for photopost there.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Old February 6th, 2006, 03:08 PM   #27 (permalink)
Member
Verified Customer
 
Join Date: Jun 2005
Posts: 34
Quote:
Originally Posted by Chuck S
Well make sure if your trying to access a database in some non database program you uncomment the $link and mysql_select_db lines at the top of the file and put the proper database info for photopost there.
Fantastic! I got it to work. The only problem is now a database connection (unrelated to PhotoPost) below where I call out the PhotoPost featured image is now broken. I tried closing everything on inc_features.php, but nothing seems to work. Any ideas?

Thanks so much!
thirtytwo16 is offline   Reply With Quote
Old February 6th, 2006, 03:09 PM   #28 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 68,070
You uncomment the mysql_select_db at the bottom of the script and put in the name of the database that your using on that page
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Old February 6th, 2006, 03:14 PM   #29 (permalink)
Member
Verified Customer
 
Join Date: Jun 2005
Posts: 34
Quote:
Originally Posted by Chuck S
You uncomment the mysql_select_db at the bottom of the script and put in the name of the database that your using on that page
Cool! I tried that before, but didn't work. I just completely called out the WHOLE connection again, and we're working fine. Thanks so much!!!!
thirtytwo16 is offline   Reply With Quote
Old February 6th, 2006, 07:07 PM   #30 (permalink)
Junior Member
Verified Customer
 
Join Date: Jan 2006
Posts: 20
Ok.. I made the file test.php with code
Quote:
<?

echo <<<HTML

SOME GOES HERE

HTML;

include('../photoalbums/htdocs/inc_features.php');

echo "$photopostfeature";

echo <<<HTML

maybe some more html here

HTML;

?>
I get nothing.
Here is the link

http://www.disneypost.com/test.php
disneypost is offline   Reply With Quote
Old February 6th, 2006, 08:58 PM   #31 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 68,070
Did you remove the viewperms as noted earlier in this thread. Your getting the code just no photos
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Old February 6th, 2006, 09:06 PM   #32 (permalink)
Junior Member
Verified Customer
 
Join Date: Jan 2006
Posts: 20
Yes, I removed the code, as you stated.. now Chuck, could it be this.

my photopost is located in --> http://photoalbums.disneypost.com
and I am running the php from ----> http://www.disneypost.com

which means it trying to look for my inc_features.php in

http://www.disneypost.com/photoalbums/htdocs/inc_features.php' ??
disneypost is offline   Reply With Quote
Old February 6th, 2006, 09:09 PM   #33 (permalink)
Junior Member
Verified Customer
 
Join Date: Jan 2006
Posts: 20
Chuck, I got go it to work with
<?php
$host = xxxx;
$dbUser = 'xxx';
$dbPass = 'xxx';
$db = 'xxxxx';
mysql_connect("$host", "$dbUser", "$dbPass") or die(mysql_error());
mysql_select_db("$db") or die(mysql_error());

$result = mysql_query("SELECT id,cat,bigimage FROM pp_photos order by rand() LIMIT 4" ) or die(mysql_error());
while($row = mysql_fetch_array( $result )) {
print "<a href=\"http://photoalbums.disneypost.com/showphoto.php?photo=" . $row['id'] . "\"><img src=\"http://photoalbums.disneypost.com/data/" . $row['cat'] . "/thumbs/" . $row['bigimage'] . "\" border=\"0\"></a>";
}
?>

For some reason.
disneypost is offline   Reply With Quote
Old February 6th, 2006, 09:09 PM   #34 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 68,070
You removed this?

Code:
Content visible to verified customers only.
Your getting no $featured printed at all in the page

Use whatever code you want that works for you.
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Old February 6th, 2006, 09:13 PM   #35 (permalink)
Junior Member
Verified Customer
 
Join Date: Jan 2006
Posts: 20
Yes I removed
if ( $ViewPerm[$pcat] == 1 ) continue;

ummm.. Chuck, is it my path? are you sure I can't use a http:// instead of a path?
disneypost is offline   Reply With Quote
Old February 6th, 2006, 09:21 PM   #36 (permalink)
Photopost Developer
Verified Customer
 
Chuck S's Avatar
 
Join Date: Jun 2002
Location: Abingdon,MD
Posts: 68,070
You do not use a url in the place of a path.

If your concerned about your path just put the full server path to the file instead of ..
__________________
Photopost Developer and Support Engineer

Please do not PM me for support or sales questions. Thank you for your understanding.
Chuck S is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Random Gallery on non-VB pages StuartDH How Do I? - vBulletin 3.0.X 3 September 24th, 2005 11:58 AM
How to show featured photos on Non-Photopost pages? woodwater Photopost Pro How Do I...? 4 May 27th, 2005 04:37 AM
Random Images on VB Pages and NON-Vb Pages SaN-DeeP Photopost Pro How Do I...? 5 March 31st, 2005 10:13 AM
How do I setup the Featured Photo / Random Image on index vB page? Fenriz Photopost Pro How Do I...? 5 March 4th, 2005 04:53 PM


All times are GMT -5. The time now is 11:18 AM.

Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0