+ Reply to Thread
Page 4 of 4 FirstFirst ... 234
Results 31 to 38 of 38

Thread: Trying to add the following php script...

  1. #31
    Quote Originally Posted by Viktor View Post
    Hello Brian,

    Please write:

    PHP Code:
    Only registered members can view the code
    and check what a key will be on the login page and add this key to the condition.
    Hello Viktor,
    i just powered up my server, I shut down last night, and the flag in the header now works when I go to the login page, but the code is still not working on these pages:

    aboutus
    contactus
    category pages
    location pages

    here's the condition in my common.inc.php file:

    Code:
    Only registered members can view the code.
    Brian

  2. #32
    Hello Viktor,

    Sorry for the delay, I forgot to make an adjustment to my php.ini file to display_error: on.

    After adding this code:
    Code:
    Only registered members can view the code.
    and checking my about page, I am getting about_us as the name of the page

  3. #33
    Ok,

    Still not done, but YES, I did get something figured out (all the pages, EXCEPT, LOCATION PAGES)...What I need to do now, is get the flag to work on the location pages, is that possible? Ex: I change to another location and the header flag stays on page?

    Code:
    Only registered members can view the code.
    and the links have to be like this: (I pasted the entire html for my links, but note the html on the links)

    Code:
    Only registered members can view the code.
    Brian

  4. #34
    I have rebooted my server, and all is working as it should...I apologize again, for the lack on my part...But sometimes a kick in the pants can go quite far...

    Thank you!
    Brian

  5. #35
    Quote Originally Posted by Viktor View Post
    Hello Brian,

    You created an array with image name and url but then you scan the directory with images.
    Do you want to show random flag?
    You can randomize it without scanning the directory. Also please read my comments in the code. You created smarty condition in php file!
    Use my file!
    Hello Viktor,

    Based on your message:
    You can randomize it without scanning the directory. Also please read my comments in the code. You created smarty condition in php file!
    I have this code working based on having it scan the directory and using an array, but my question is there a way to just use one of those two methods? As long as the code will change the image (flag) every 24 hours at mid-night, which I have already, but it's using both the scan the directory and the array, can that code be shorter (example, with just one without the other method?)

    PHP Code:
    Only registered members can view the code

  6. #36
    Hello Brian,

    I can make it works with array only. But it will not work with scanning the folder because where the system should take the link to the image?
    Viktor,
    Flynax technical department,
    Best wishes.

  7. #37

    Hello Brian,

    I can make it works with array only. But it will not work with scanning the folder because where the system should take the link to the image?

    Hello Viktor,

    As long as the script will display the flag on the 24 hour interval,
    meaning one flag will display from 12:00am till 12:00am the next day,
    then the next image will do the same etc..etc..It doesn't matter if you
    use the array method or scan the folder. The script currently works that
    way, I just want you to remove one of the methods being used.

    Brian

  8. #38
    You are using scan folder for show image but $links array you are using for set url for the tag 'a' need both methods.
    Viktor,
    Flynax technical department,
    Best wishes.

+ Reply to Thread