| We hope you enjoy your visit. You're currently viewing our forum as a guest. This means you are limited to certain areas of the board and there are some features you can't use. If you join our community, you'll be able to access member-only sections, and use many member-only features such as customizing your profile, sending personal messages, and voting in polls. Registration is simple, fast, and completely free. Join our community! If you're already a member please log in to your account to access all of our features: |
- Pages:
- 1
- 2
| Modding PHP Files | |
|---|---|
| Tweet Topic Started: May 2 2005, 01:28 AM (631 Views) | |
| Das | May 2 2005, 01:28 AM Post #1 |
![]()
Smells of rich mahogany
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Few question: 1) Is there a php script that would allow you to change a php file 2) Is there a php script that creates a new php page 3) Can you run an if statement through an if statment
|
![]() |
|
| Seth | May 2 2005, 02:06 AM Post #2 |
|
I has a pony
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
http://php.net/fopen http://php.net/fwrite
|
![]() |
|
| Das | May 2 2005, 02:16 AM Post #3 |
![]()
Smells of rich mahogany
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
I get two ... wait no just one Is there a way to replace text with a script? Like change <a href="stuff.com">stuff</a> to <a href="bob.com">bob</a> ? |
![]() |
|
| kingy | May 2 2005, 04:32 AM Post #4 |
|
1 in 10 people understands binary, the other 1 doesn't
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
To check 2 variables, you could also do this
|
![]() |
|
| Jory | May 2 2005, 06:16 AM Post #5 |
|
Member
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Sure there is. http://www.php.net/manual/en/function.preg-replace.php That shows you how to. |
![]() |
|
| Seth | May 2 2005, 09:56 AM Post #6 |
|
I has a pony
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
But my script has more cases. It outputs different messages if User 1 is not logged in and if User 1 is logged in but doesn't have enough points
|
![]() |
|
| Seth | May 2 2005, 09:59 AM Post #7 |
|
I has a pony
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Although note that PHP is not dynamic. All work must be done before you send the page to the user. |
![]() |
|
| Das | May 2 2005, 11:13 AM Post #8 |
![]()
Smells of rich mahogany
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
I am trying to transfer a user's registration over. I get a parse error on line 5. I think I am missing something blantantly odvious, but I got to go to school. can anyone see my problem? |
![]() |
|
| Seth | May 2 2005, 11:24 AM Post #9 |
|
I has a pony
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
I'm so confused. That's like the completely wrong way to go about what you're doing. For example: "<? $name = $name $pass = $pass if ($name == $_POST[" There's the parse error since you have two double quotes. The string ends there. |
![]() |
|
| Das | May 2 2005, 02:53 PM Post #10 |
![]()
Smells of rich mahogany
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Then what would be the right way to write that infromation to the other file? If the answer to this question is yes it would make things alot easier. Can you have a global variable? Like $cat = "dog" on all page in a domain, or in all pages in a folder? |
![]() |
|
| Seth | May 2 2005, 03:08 PM Post #11 |
|
I has a pony
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
No. ![]() What info are you trying to write? Take a peek at IdioPoll, functions.php, writeconfig() for an example of writing to file. |
![]() |
|
| Das | May 2 2005, 07:09 PM Post #12 |
![]()
Smells of rich mahogany
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
With Sql? |
![]() |
|
| JCink | May 2 2005, 07:25 PM Post #13 |
|
Member
![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
2) Is there a php script that creates a new php page
yes. thats it. |
![]() |
|
| Das | May 2 2005, 08:27 PM Post #14 |
![]()
Smells of rich mahogany
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
Do you know if SQL can create a global variable? |
![]() |
|
| Dennis | May 2 2005, 08:36 PM Post #15 |
|
Member
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]()
|
SQL is a database, not a language. So no, it cannot. You can, however, pull a row out of the database, and assign it to a PHP variable, if that's what you mean. |
![]() |
|
| 1 user reading this topic (1 Guest and 0 Anonymous) | |
| Go to Next Page | |
| « Previous Topic · Technology Chat · Next Topic » |
- Pages:
- 1
- 2
| Track Topic · E-mail Topic |
4:19 AM Jul 11
|




![]](http://b1.ifrm.com/0/1/0/p601690/pipright.png)




4:19 AM Jul 11