Witaj Gościu! ( Zaloguj | Rejestruj )

Forum PHP.pl

> Pomoc ze zmiana system() na redfile
xirus
post 11.02.2009, 11:58:07
Post #1





Grupa: Zarejestrowani
Postów: 7
Pomógł: 0
Dołączył: 30.05.2008

Ostrzeżenie: (0%)
-----


Witam zmieniłem hosting i teraz mam nastepujacy problem zablokowane jest na nim polecenie system() kiedys dawno dawno zrobilem sobie panel zarzadzania trescia ale byl on na poleceniach sytem() wiec teraz mi niedziala. z pomocy cos mowili mi zeby zastapic je poleceniami redfile() ale nieidzie mi to wogole. czy ktos bardziej znajacy sie na php moglby mi pomoc questionmark.gif

pokazuje kod zrodlowy pliku admin.php

Kod
[/b]
    <table width=585 bgcolor=#60a3d9>
        <tr><td align="left"><font color=#ffffff size=1>&nbsp;&nbsp; Panel administracyjny - administracja</font></td></tr>
        </table>
        
        <table width=585 bgcolor=#ececec>

        <tr><td align=center><br><br>    
        <?php
        $menu=$_GET[menuitem];
        if(($_COOKIE["access"]==1)||($access))
        {
            switch($menu)
            {
            case 0:
            print ("

Witaj na stronie edycji tekstu

<br><br>

            <form action=index.php method=post><input type=submit name=submit value='Wyloguj się'>
            ");
            break;
            
            
            case 1:
                        print ("* Strona Główna<br><br>");
                        print ("<form method=\"post\" action=\"mod_1.php\">");
                        print ("<TEXTAREA NAME=\"tekst1\" value=\"dupa\" ROWS=20 COLS=50>");
                        readfile("cat ../herbet/index.php");
                        print ("</TEXTAREA><br><br>");
                        print ("<input type=\"submit\" name=\"Submit\" value=\"Zapisz\"><br>");
            break;

            case 2:
                        print ("* Oferta<br><br>");
                        print ("<form method=\"post\" action=\"mod_2.php\">");
                        print ("<TEXTAREA NAME=\"tekst1\" value=\"dupa\" ROWS=20 COLS=50>");
                        system("cat ../herbet/oferta.php");
                        print ("</TEXTAREA><br><br>");
                        print ("<input type=\"submit\" name=\"Submit\" value=\"Zapisz\"><br>");
            break;

            case 3:
                        print ("* Cennik<br><br>");
                        print ("<form method=\"post\" action=\"mod_3.php\">");
                        print ("<TEXTAREA NAME=\"tekst1\" value=\"dupa\" ROWS=20 COLS=50>");
                        system("cat ../herbet/cennik.php");
                        print ("</TEXTAREA><br><br>");
                        print ("<input type=\"submit\" name=\"Submit\" value=\"Zapisz\"><br>");
            break;

            case 4:
                        print ("* Kontakt<br><br>");
                        print ("<form method=\"post\" action=\"mod_4.php\">");
                        print ("<TEXTAREA NAME=\"tekst1\" value=\"dupa\" ROWS=20 COLS=50>");
                        system("cat ../herbet/kontakt.php");
                        print ("</TEXTAREA><br><br>");
                        print ("<input type=\"submit\" name=\"Submit\" value=\"Zapisz\"><br>");
            break;


            }
        }
        else print ("Niepoprawne hasło!");
        ?>
        <br><br><br>


        </center>        
        </td>
        </td></tr></table>
                <table width=585 bgcolor=#60a3d9><tr><td></td></tr></table>

        <br>

</td>



<td width="220" height="316" valign="top">
<center><b>MENU EDYCJI</b></center><br>


<a href=./admin.php?menuitem=1>&nbsp;&nbsp; Strona Główna</a><br>
<a href=./admin.php?menuitem=2>&nbsp;&nbsp; Oferta</a><br>
<a href=./admin.php?menuitem=3>&nbsp;&nbsp; Cennik</a><br>
<a href=./admin.php?menuitem=4>&nbsp;&nbsp; Kontakt</a><br>




<center>
<br><br><br>
<form action=index.php method=post><input type=submit name=submit value='Wyloguj się'>
[b]




pokazuje kod zrodlowy pliku mod_1.php dla przykadlu :

Kod
[/b]
<table width=500 border=0>
<font size=2>
<?php
$string=$_POST[tekst1];
system("echo \"" . $string . " \" >../herbet/index.php");
print ("<br>Edytowany tekst:<br><br>");
print("<table width=480 bgcolor=#eeeeee border=1> <font size=2><tr><td><center>");
echo $string;
print("</td></tr></font></table>");
print ("<br><font size=2> Pomyslnie zapisano.");
?>

<br>
<br>
<br>
<form action=./admin.php method=post><input type=submit name=submit value='Powrót'>
</font>
</table>
[b]


Ten post edytował xirus 11.02.2009, 19:22:04
Go to the top of the page
+Quote Post

Posty w temacie
- xirus   Pomoc ze zmiana system() na redfile   11.02.2009, 11:58:07
- - batman   Proszę dodać poprawny bbcode do posta.   11.02.2009, 12:21:37


Reply to this topicStart new topic
1 Użytkowników czyta ten temat (1 Gości i 0 Anonimowych użytkowników)
0 Zarejestrowanych:

 



RSS Wersja Lo-Fi Aktualny czas: 23.06.2025 - 04:09