Activity Stream
48,167 MEMBERS
62931 ONLINE
besthostingforums On YouTube Subscribe to our Newsletter besthostingforums On Twitter besthostingforums On Facebook besthostingforums On facebook groups

Results 1 to 7 of 7
  1.     
    #1
    Member
    Website's:
    maxneeds.info

    Question One source var - how to split?

    Guys i have the following problem.
    I made 2 buttons below each entry.
    Working & Not Working.
    When working button is clicked,a file named wknwk.html is saved in the place for current entry.But instead of that it saves the wknwk.html file in last 5 entries. Here some code

    Code: 
    $admin = $_SESSION[ fulladmin ];
    if ($admin == yes ) {
    $str = $str . '<form method="POST">
    <input class=submit type="submit" name="z3" value="Working">
    <input class=submit type="submit" name="z3" value="Not Working">
    </form>'
    ;}
    if(isset($_POST['z3']))
    {    $wknwk   = $_POST['z3'];
    	if ($wknwk=="Working"){$wknwk="Last checked : <font color=green>" . date("d/m/Y") . "</font>";}
    	else {$wknwk="<font color=red>Dead link/s !</font>";}
    }
    $myfile = $comment_trackback_base.'wknwk.html';
    $fh = fopen($myfile, 'w') or die("Having problems right now...");
    fwrite($fh, $wknwk);
    fclose($fh);
    The bolded code is the path for saving that wknwk.html file,which is equal to...
    Code: 
     $comment_trackback_base = CONTENT_DIR.$y.'/'.$m.'/'.$entry.'/';
    So from here comes the problem,but i don't know how to solve it.

    Thanks.

    I need explode or something ?
    Porsche_maniak Reviewed by Porsche_maniak on . One source var - how to split? Guys i have the following problem. I made 2 buttons below each entry. Working & Not Working. When working button is clicked,a file named wknwk.html is saved in the place for current entry.But instead of that it saves the wknwk.html file in last 5 entries. Here some code $admin = $_SESSION; if ($admin == yes ) { $str = $str . '<form method="POST"> <input class=submit type="submit" name="z3" value="Working"> <input class=submit type="submit" name="z3" value="Not Working"> Rating: 5

  2.   Sponsored Links

  3.     
    #2
    Member
    Website's:
    maxneeds.info
    someone ?

  4.     
    #3
    Member
    Website's:
    epicimagehost.com
    try changing
    $comment_trackback_base = CONTENT_DIR.$y.'/'.$m.'/'.$entry.'/';
    to

    $comment_trackback_base = CONTENT_DIR.&$y.'/'.&$m.'/'.&$entry.'/';

    Not sure tho as i'm quite noobish myself

    what it does:
    http://www.whypad.com/posts/php-what...variables/193/

  5.     
    #4
    Member
    Website's:
    maxneeds.info
    It gives unexpected '&' ...

  6.     
    #5
    Member
    Website's:
    epicimagehost.com
    try replacing

    $myfile = $comment_trackback_base.'wknwk.html';
    with
    $myfile = CONTENT_DIR.$y.'/'.$m.'/'.$entry.'/wknwk.html';

    If it still happens try to echo the location
    ( echo CONTENT_DIR.$y.'/'.$m.'/'.$entry.'/wknwk.html';exit; )

  7.     
    #6
    Member
    Website's:
    maxneeds.info
    No man thats not the problem...

    Maybe when 1 button is clicked ... all buttons are clicked ,because they all are with same 'name' ?
    And thats why it sends wknwk.html to all directories instead of the clicked one ?

  8.     
    #7
    Respected Member
    Are there multiple lines of buttons working/not working with different entries?
    Without seeing the form it is pure guessing what you are trying to do?

    In the code shown it does not show how entry is being defined and stored.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Split the hosting up.
    By GeeZus in forum Feedback and Suggestions
    Replies: 1
    Last Post: 13th Jun 2012, 01:44 PM
  2. Replies: 1
    Last Post: 29th Feb 2012, 04:41 AM
  3. does a streaming vid need to be split
    By jetli68 in forum Tutorials and Guides
    Replies: 2
    Last Post: 23rd Dec 2011, 12:00 PM
  4. Split avi
    By zoug100 in forum General Discussion
    Replies: 2
    Last Post: 20th Dec 2011, 05:40 PM
  5. How to split vps space ??
    By shufol in forum Technical Help Desk Support
    Replies: 2
    Last Post: 6th Nov 2010, 07:00 PM

Tags for this Thread

BE SOCIAL