+ Reply to Thread
Results 1 to 3 of 3

Thread: Need a script made.

  1. #1
    Barn Newbie jpaytoncfd is an unknown quantity at this point jpaytoncfd's Avatar
    Join Date
    May 2009
    Posts
    27
    Rep Power
    3

    Need a script made.

    I need what I thought would be a pretty basic script but I cant make it work.

    Basically I need to have a form that lets me put a username. it will then need to add a directory named whats entered into the username, unzip a zip file into the new directory, and edit another file.

    Code:
    	/** ensure this file is being included by a parent file */
    	defined( "_VALID_MOS" ) or die( "Direct Access to this location is not allowed." );
    	$GLOBALS["users"]=array(
    	array("admin","*********************","/home/synthet/public_html","http://localhost",1,"",7,1),
    );
    
    So I need to have this added below that code, $uname = $_POST['username']

    Code:
    array("$uname","ee11cbb19052e40b07aac0ca060c23ee","/home/synthet/public_html/sites/$uname","http://syntheticmotorsports.org/sites/$uname",0,"",3,1),
    
    Last edited by jpaytoncfd; June 12th, 2009 at 01:11 PM.

  2. #2
    Barn Newbie jpaytoncfd is an unknown quantity at this point jpaytoncfd's Avatar
    Join Date
    May 2009
    Posts
    27
    Rep Power
    3

    BTW the new directory needs to be at /public_html/sites/

    Can it be done?
    I cant really offer anything. I do have a cupon code for hosting24.com. $50 per year unlimited hosting.

    I'd apperiate it very much,
    ~Joe

  3. #3
    Barn Newbie jpaytoncfd is an unknown quantity at this point jpaytoncfd's Avatar
    Join Date
    May 2009
    Posts
    27
    Rep Power
    3

    Quote Originally Posted by jpaytoncfd View Post
    BTW the new directory needs to be at /public_html/sites/

    Can it be done?
    I cant really offer anything. I do have a cupon code for hosting24.com. $50 per year unlimited hosting.

    I'd apperiate it very much,
    ~Joe
    ok so I think I have the first two parts, making the folder and unpacking the zip file but now I need to add a line to this file:

    Code:
    <?php 
    	/** ensure this file is being included by a parent file */
    	
    	defined( "_VALID_MOS" ) or die( "Direct Access to this location is not allowed." );
    	$GLOBALS["users"]=array(
    		array("admin","f23f4268d1775d129d28f328065aba1c","/home/synthet/public_html","http://localhost",1,"",7,1),
    		array("bigdaddydiesel","81dc9bdb52d04dc20036dbd8313ed055","/home/synthet/public_html","http://localhost",0,"",3,1),
    		array("hi","ee11cbb19052e40b07aac0ca060c23ee","/home/synthet/public_html/sites","http://syntheticmotorsports.org/sites/",0,"",3,1),
    ); 
    ?>
    
    it needs to add:
    Code:
    array($uname,"ee11cbb19052e40b07aac0ca060c23ee","/home/synthet/public_html/sites". $uname,"http://syntheticmotorsports.org/sites/". $uname,0,"",3,1),
    
    $uname being the username entered on the form. I know how to add it to the file but it has to be added below or above the existing arrays and not the end of the page.
    I tried to list the arrays in another file and use and include_once but it wouldent work. it just showed the arrays on the login page and wouldent login

+ Reply to Thread

Similar Threads

  1. Simple script to modify csv file
    By grae.uk in forum Windows Scripting
    Replies: 4
    Last Post: June 11th, 2009, 08:35 AM
  2. altering a script
    By Shem in forum JavaScript Programming
    Replies: 2
    Last Post: May 18th, 2009, 10:23 AM
  3. Basic Login Script (using MS Acesss)
    By BLaaaaaaaaaarche in forum ASP Code Samples
    Replies: 0
    Last Post: March 24th, 2008, 05:50 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

SEO by vBSEO