Search found 13 matches

by shylor
Sun Sep 30, 2007 1:25 pm
Forum: PHP - Code
Topic: reading a php file with php
Replies: 2
Views: 234

ok thanks, I was unsure if those could read the raw php file.
by shylor
Sun Sep 30, 2007 5:47 am
Forum: PHP - Code
Topic: reading a php file with php
Replies: 2
Views: 234

reading a php file with php

ok, in order for me to make my update script I need a way to read php files, with php. What I mean by this is, I need to update code line by line. I can not make an update to a html file, because then its not really updating what needs to be updated. I might have to add another variable to a config ...
by shylor
Sat Sep 29, 2007 12:13 am
Forum: PHP - Code
Topic: inline code updating
Replies: 8
Views: 731

$file_contents = str_ireplace ($old_code, $new_code, $file_contents) Would I need to add % around the old code? edit: ok I told my script to echo $file_contains and it echoed nothing. I seen there was a warning with php below 6 on php.net. update: ok, I found out that for some reason it can not rea...
by shylor
Thu Sep 27, 2007 11:55 pm
Forum: PHP - Code
Topic: Account Verification
Replies: 4
Views: 363

I use mt_rand() with at md5() on top. then stuff it into the database until the user clicks the link!
by shylor
Thu Sep 27, 2007 11:41 pm
Forum: PHP - Code
Topic: inline code updating
Replies: 8
Views: 731

Ok, stripos and str_ireplace are new to me, well I run dream weaver cs3 and for some reason it will not show the case sensitive ones to show up. <?php if($file_contains = @file_get_contents('index.php')) { $code_1 = '$server = \'test one two three\''; $patch_1 = '$server = \'test three two one\''; i...
by shylor
Thu Sep 27, 2007 9:20 pm
Forum: PHP - Code
Topic: jQuploader - upload file
Replies: 3
Views: 578

remember that you can always edit your post.
by shylor
Thu Sep 27, 2007 9:17 pm
Forum: PHP - Code
Topic: Session management
Replies: 4
Views: 442

Here is a login.php file I use when I have the user login. The forum is on the index.php <?php session_start(); include('config.inc.php'); $login_raw = mysql_query("SELECT * FROM `*` WHERE `username` = '".$_POST['username']."' AND `password` = '".md5($_POST['password'])."'&q...
by shylor
Thu Sep 27, 2007 8:47 pm
Forum: PHP - Code
Topic: inline code updating
Replies: 8
Views: 731

you mean old code, where you put out code? Oh and what about a new line, how would I add a new line between 79 and 80?
by shylor
Thu Sep 27, 2007 7:34 pm
Forum: PHP - Code
Topic: inline code updating
Replies: 8
Views: 731

Ok, I will go a little bit more detail with this, I would say I am a medium php programmer, I still can not do a lot of the really really advanced stuff, but I feel I have a good foot hold. Ok, you get a web script, its a webportal its version 1.00.00. The next week a new patch comes out, but it add...
by shylor
Thu Sep 27, 2007 7:08 pm
Forum: PHP - Code
Topic: Sessions
Replies: 7
Views: 838

No problem, glad to help!
by shylor
Thu Sep 27, 2007 5:12 pm
Forum: Javascript
Topic: How do I get a div to act like a table?
Replies: 10
Views: 4030

Yes, I just started to learn CSS and I agree with above. If your information needs to be in a table so be it. Just do not program your whole page in tables. CSS is a very powerful language, but CSS will mess up a table if the page is not displayed right for some reason.
by shylor
Thu Sep 27, 2007 5:09 pm
Forum: PHP - Code
Topic: Sessions
Replies: 7
Views: 838

When the header function is sent twice that error will happen. So you might have this line in your main file and in another file that is included to the first file. header() and with sessions starts, they must always be on the top of the page at hand. you must open the php page and start the session...
by shylor
Thu Sep 27, 2007 4:52 pm
Forum: PHP - Code
Topic: inline code updating
Replies: 8
Views: 731

inline code updating

I am not really even sure where to start to look up this information, because well, I am not even sure what to call it. Anyways on topic. I just started to write my own scripts, and I would like to be able to update the pages without having to replace the whole page. I have seen this with other bigg...