need php help

Discussion in 'Scripts, 3rd Party Apps, and Programming' started by NewFuture, Oct 7, 2005.

  1. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    if you are good with php plz contact me through msn, or AIM:

    bendurham90@hotmail.com

    stuartdurham15

    as i urgently need your help
     
  2. Mani5

    Mani5 New Member

    Messages:
    946
    Likes Received:
    0
    Trophy Points:
    0
    I m gud but not wid scripts........
     
  3. motogawa

    motogawa Member

    Messages:
    306
    Likes Received:
    0
    Trophy Points:
    16
    I'm good with php and all
     
  4. Bryon

    Bryon I Fix Things

    Messages:
    8,149
    Likes Received:
    101
    Trophy Points:
    48
    Ask for help you need in the forums, so you can be answered and maybe even others will learn from it.

    I thought about messaging you on AIM, but, like I said, post in here first. I'm willing to help.
     
  5. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    its complicated, my friends owns a flash site, and on the links to his flash games instead of directing to the actual game he uses some kind of php 'thing' which hides url but loads the game (see link)

    hes got HISWEBSITE/game.php?type=puzzle&game=aqua&height=400&width=550

    and not the actual url, he told me its some kind of php script, could someone help me make my site work like that? so the location of the game isnt been show but the php link instead.
     
  6. Mani5

    Mani5 New Member

    Messages:
    946
    Likes Received:
    0
    Trophy Points:
    0
    ...I dont got an idea but chk hotscripts.com......
     
  7. motogawa

    motogawa Member

    Messages:
    306
    Likes Received:
    0
    Trophy Points:
    16
  8. Bryon

    Bryon I Fix Things

    Messages:
    8,149
    Likes Received:
    101
    Trophy Points:
    48
    Ok.. So what exactly do you want to know? Where the games truly are? All that is, is a way to show any game in the one script, depending on the values of the variables in the URL.
     
  9. ak007

    ak007 Member

    Messages:
    216
    Likes Received:
    0
    Trophy Points:
    16
    Ahh I Know What he Means Maybe He Wana Hide Real SWF And Make The Page A Little Bit Dynamic By Passing Var From Th Query String It Would me Much Better If You Use database But Without Db here How It looks Like :

    PHP:
    <?php
    if(empty($_GET[name]) || empty($_GET[width]) || empty($_GET[height]) || empty($_GET[quality])){
    echo 
    "Direct Access not Allowded!";
    exit;
    }
    //here Come Some Config Stuff
    //Replace With Your Site Url With Directory With trailing Flash!!!!!
    $basedir "http://yoursite.com/flashfiles/";
    ?>
    <object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" width="<?=$_GET[width]?>" height="<?=$_GET[width]?>" id="Game" align="middle">
    <param name="movie" value="<?=$basedir.$_GET[name]?>.swf" /><param name="quality" value="<?=$_GET[quality]?>" /><param name="bgcolor" value="#ffffff" /><embed src="<?=$basedir.$_GET[name]?>.swf" quality="<?=$_GET[quality]?>" bgcolor="#ffffff" width="<?=$_GET[width]?>" height="<?=$_GET[width]?>" name="Games" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
    Note :
    The URL MUST Look Like This !:
    hxxp://site.com/anypgate.php?name=main&width=800&height=400&quality=high

    And You Must Upload All You SWF File To The Directory You Specified Above FOR Example
    If The name of your swf file you upload is mafia.swf then you must pass the name in the address barlike this:
    hxxp://site.com/anypgate.php?name=mafia&width=800&height=400&quality=high

    Without The .swf!! Comments And Questions are welcomed !!
    And Don't Expect So much From That Script Ive Made It Within 3 minutes ;)
     
    Last edited: Oct 8, 2005
  10. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    yes great thanx, and no i dont wanna know where the games are, i just wanted to know how he was using the code
     
  11. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    i have pm'd you plz reply
     
  12. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    the page on my site www.newfuture.tk with all the catogory images can i still have that on the php page which will be in the iframe?- i also need your help
    ak007 vbmenu_register("postmenu_58880", true); so sign into msn plz
     
    Last edited: Oct 9, 2005
  13. chitwa

    chitwa New Member

    Messages:
    128
    Likes Received:
    0
    Trophy Points:
    0
    Well i think its actually a page called game.php that chooses the game you want according to what you click.

    HISWEBSITE/game.php?type=puzzle&game=aqua&height=400&width=550.

    In the link above, everything else after 'game.php' is generated by the button you click. It generates data to search the database i.e " type = 'Puzzle' game='aqua'" Its very doable by the way
     
  14. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    ha ha, could someone make it work with a database then with all codes and instructions plz?
     
    Last edited: Oct 9, 2005
  15. 03moscropl

    03moscropl Flash Freak

    Messages:
    698
    Likes Received:
    0
    Trophy Points:
    0
    i am not good but i recomed in taking a look at this script its really a module but it is cool!

    pnflashgames.com
     
  16. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    can any one help me set this up plz?
     
  17. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
  18. 03moscropl

    03moscropl Flash Freak

    Messages:
    698
    Likes Received:
    0
    Trophy Points:
    0
    perhaps you should move it and place it under request and a dd a reward of points that might make pople want to help!:roflwerd:
     
  19. NewFuture

    NewFuture New Member

    Messages:
    1,658
    Likes Received:
    0
    Trophy Points:
    0
    yes, i am rewarding points, and i cnat move posts
     
  20. oab

    oab New Member

    Messages:
    918
    Likes Received:
    0
    Trophy Points:
    0
    okay let me see if i can help you.


    each game you have should have a button that says 'click here to play' or somthing, this is the code for the button:
    HTML:
    <form method="post" action="play.php">
    <input name="game" type="hidden" value="name of game"> \\change "name of game" to the name of the game this button is being used for.
    <input name="submit" type="Submit" value="Play the Game!" >
    </form>
    
    You should create a file named play.php with these contents:
    PHP:
    <?
    $game $_POST['game'];
     
    if (
    $game == "name of 1st game"){
    ?>
    html code to display game number 1
    <?
    }
     
    elseif ($game == "name of 2nd game"){
    ?>
    html code to display game number 2
    <?
    }
     
    elseif ($game == "name of 3rd game"){
    ?>
    html code to display game number 3
    <?
    }
     
    ?>
    In this script i used the post action on the form because i am not very familiar with how the get action works, so it wont even have any variables in the url it will always just be play.php, which means you cant bookmark a page with a certain game on it.. which is not very good, if some1 can improve on this it would be great.
     

Share This Page