neel_basu
Members-
Posts
593 -
Joined
-
Last visited
Never
Everything posted by neel_basu
-
I Didn't understand anything from your Post. Please explain more.
-
I am confused with your Question. Do you wanna sort an array Alphabatically ?? Use sort() to do that.
-
If teh port is 3306 Only $dbServer='xxx.xxx.xxx.xxx';//Will work.
-
You keep saying 'ask your host'. How do you know the OP is not trying to develop a deployable application? [i've provided him alternatives also] Hosting Companies server is set up in such a way that you have permission to do a very few things in shell and with that you cant do any deployable application. But I think they should tell him. else rely upon PHP CLI php -f yourscript.php Cause we dont know where is the php is it in bin or sbin ----------------------------------------------------- See your PATH it would be like PATH /usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games Check with all of this 1 By 1 e.g. /usr/local/sbin/php /usr/local/bin/php /usr/sbin/php Bla Bla ...... Else ----------------------------------- Can you read your .profile if yes get the value of PATH from it and check in teh Previous way else ----------------------------------------- Make a shell script and in it try using php -f yourscript.php
-
If PHP CLI is Installed in your server And If you just use php -f yourscript.php It should work. if it doesnt work ask your host.
-
But why do you need that ?? Ask your hosting company they will tell you that Information.
-
I agree with You It can be solved in this Way If everything On your site depends on status = 1 if found that status = 0 while working ask him to relogin /* If status is 1 Currently Dont oevewrite it with 1 again make it 0 then make it 1 */ When User tries to login from a Different PC ask him to Sign Out. When He Signs Out. Then status = 0. So teh Previous PC gets Sign Out. Now login the Current User
-
Detecting if a string has a certain character?
neel_basu replied to rottenpixies's topic in PHP Coding Help
Ya I agree with thorpe if(strpos($string, 'c')) { //Yes } else { //No } //Assuming that teh Character is c -
Just make another field in your Table named `status` or something like this And when a user log's In set the status to 1 and when User Logs Out make it 0. and When User loges In first make sure that status is 0. If not ask him Log out First.
-
charcters in UNIX file and directory names
neel_basu replied to mridang_agarwal's topic in PHP Coding Help
UNIX filenames or Directory name can contain anything other than a / Character. I dont have Windows I use Linux In windows Create a new file and then try renaminf it to a String that contains a / when you press that Windows will show you which characters are not Allowed -
Whats teh location of teh php file you run ?? http://localhost/????????????? Open your htdocs folder. Is there any .htaccess file ?? If there is Paste its contents here.
-
NOt tested at all ^(?:http://)([^/]+)/(?:.*)
-
Your host doesnt allows you to use external Contents to stop Abuse and spam e.g. allow_url_fopen is turned Off.
-
YOU ran this Code ?? Whats its output.
-
Download MySQL GUI Its free Back your home db and restore that backuped sql file on Your Server's DB.
-
Use $_GET['code'] Instead of just $code
-
1.Run this Query on MySQL CLI or PHPMyAdmin And see what are the Results there. 2 I cant see your mysql_connect() Assuming your link Identifier resourse variable is $conn $query = mysql_query("SELECT * FROM availability WHERE c_id='1'", $conn); //Bla Bla Bla $array = mysql_fetch_row($query, $conn); //Bla Bla Bla Hope this Works.
-
Add this line at the Top of your Script error_reporting(E_WARNING | E_ERROR);
-
[SOLVED] How to run windows .exe in Linux Environment
neel_basu replied to chenloong's topic in PHP Coding Help
Sometimes wine cant run exe files but sometimes it can. According to your description your programm is a CLI programm(DOS based). I dont think Wine can handle it. If teh programm is made by C or C++ compile its source code in Linux Environment With Gcc and then use that executable File. -
Although I didn't understand your code well(If everything is same in both if and else then why you are using if ?????) --------------------------------------------------------- You can try something like this <?php for ($i=date('Y')-1;$i<=date('Y')+2;$i++) { echo "<option value=\"$i\">$i</option>"; } echo "<option value=\"--\" selected>--</option>"; ?>
-
Just looking at the regex. --------------------------- "/[^\\]'\.?/" try using Double quote instead of Single quote Can you send a string what you wanna match ??
-
if empty($_POST['Uplgbr']) use $_GET if you use get method. else use if(empty($_FILES['userfile']['name'])) the second one is the best way to check wheather user have uploaded anything or not.
-
Gaining access to how MySql parses text for Full Text
neel_basu replied to HowdeeDoodee's topic in PHP Coding Help
Do you want something like this ?? first what values are known (e.g. Taken from Form Input) then set what what you wanna find then shor the Array automatically. All without any SQL ???? -
Just some help related to preg_replace()
neel_basu replied to matthewlesh's topic in PHP Coding Help
First of all you should post it in regex forum ------------------------------------------------------------- Your subject is "Just some help related to preg_replace()" But there is nothing about replacing in your Question Its all about ereg() and preg_match() -------------------------------------------------------------- Use this regex with ereg() or preg_match() [0-9_\$]+