Author Topic: Random Image in another php file.. Need Help Very Urgent please...  (Read 7710 times)

0 Members and 1 Guest are viewing this topic.

Offline cyber

  • Jr. Member
  • **
  • Posts: 62
    • View Profile
Hi people...
 Hi put this code in the top of my home page...

<?php
//your path Pfad to 4images-directory
$root_path = "/home/web/portal/www/htdocs/galeria/"; //(an exemple)

define('ROOT_PATH', $root_path);
include(ROOT_PATH.'global.php');
include(ROOT_PATH.'includes/sessions.php');
$random_image = $site_template->clean_template(get_random_image(0,0));
?>

and i put when i wan't the random image that:

<?php
echo $random_image;
?>

So i have that result:

www.PTGate.net/teste.php

I can't see the image.. can you help me pleasE?
I am using the last version...

Oh and i wan't to know if possible how i put only the image without a Name of the foto, the name of the member who uploads.. ONLY the image..

Help me please.. tks..

Offline Jan

  • Administrator
  • 4images Guru
  • *****
  • Posts: 5.024
    • View Profile
    • 4images - Image Gallery Management System
Random Image in another php file.. Need Help Very Urgent ple
« Reply #1 on: August 30, 2002, 11:20:49 PM »
Code: [Select]
$root_path = "/home/web/portal/www/htdocs/galeria/
Use relative pathes here!

Jan
Your first three "must do" before you ask a question:
1. Forum rules
2. FAQ
3. Search

Offline cyber

  • Jr. Member
  • **
  • Posts: 62
    • View Profile
?!?
« Reply #2 on: August 31, 2002, 01:00:32 AM »
I don't urderstand.. be more especific please...

Offline Jan

  • Administrator
  • 4images Guru
  • *****
  • Posts: 5.024
    • View Profile
    • 4images - Image Gallery Management System
Random Image in another php file.. Need Help Very Urgent ple
« Reply #3 on: August 31, 2002, 10:14:40 AM »
If the file you want to include random.php is for example in /home/web/portal/www/htdocs/web/, use:

$root_path = "../galeria/";

if the file is in /home/web/portal/www/htdocs/, use:

$root_path = "galeria/";

Jan
Your first three "must do" before you ask a question:
1. Forum rules
2. FAQ
3. Search

Offline cyber

  • Jr. Member
  • **
  • Posts: 62
    • View Profile
Tks
« Reply #4 on: August 31, 2002, 04:17:14 PM »
Weeee now rulezz... you are the best jan ;P

Give me another info please... how i put only the image without the uploader name and foto's name?

Tks

Offline Jan

  • Administrator
  • 4images Guru
  • *****
  • Posts: 5.024
    • View Profile
    • 4images - Image Gallery Management System
Random Image in another php file.. Need Help Very Urgent ple
« Reply #5 on: August 31, 2002, 04:51:33 PM »
Maybe you should use the script from here: http://www.4homepages.de/forum/viewtopic.php?t=1020

Saves your resources...

Jan
Your first three "must do" before you ask a question:
1. Forum rules
2. FAQ
3. Search

Offline cyber

  • Jr. Member
  • **
  • Posts: 62
    • View Profile
TKS
« Reply #6 on: August 31, 2002, 05:06:33 PM »
Weee rulez tks tks tks