Re: [PHP] syntax

2002-03-27 Thread Julio Nobrega Trabalhando
Make it this way: Looping first. I will loop with while: $i = 0; $array = Array(); while (list($value) = mysql_fetch_array($result)) { $array[$i] = $value; $i++; } Arrays are easier :-) Each $i will be a key. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/to

[PHP] Re: what should be my wishlist?

2002-04-02 Thread Julio Nobrega Trabalhando
Curl, gd, zlib, sockets, pdf... pear is fine but you don't need your isp to install, can have on your own directory. Humm... if possible, no safemode() enabled :-) -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.su

[PHP] Emulation: $var = print_r($array)

2002-04-04 Thread Julio Nobrega Trabalhando
Is there a way to do something like this? I wrote a wanna-be debugger. It just write to a file simple and common used function and variables, array or objects. Then when I activate it, a new window is opened with these information. Simple stuff. The problem is that if I do this: fwrite($f

Re: [PHP] Current URL, Last URL, error handling

2002-04-04 Thread Julio Nobrega Trabalhando
$REQUEST_URI? If it's not the full you can complement with $HTTP_HOST or similar. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 "Ben Edwards" <[EMAIL PROTE

Re: [PHP] Current URL, Last URL, error handling

2002-04-04 Thread Julio Nobrega Trabalhando
Okay, just phpinfo(); and use the variables. You can see whetever you will need there for url script construction. If you need, setup two pages with phpinfo() and a link between them so you can check for Referers (the Last Url you need) -- Julio Nobrega. Um dia eu chego lá: http://sourceforge

[PHP] Re: Exit();

2002-04-04 Thread Julio Nobrega Trabalhando
return; stops a function execution. Function One() { If (!$var) { return; } } -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 "Mauricio Cuenca"

[PHP] Re: Making sure a post request came from your site

2002-04-05 Thread Julio Nobrega Trabalhando
Using sessions, $HTTP_HOST, form keys, $HTTP_REFERER, ip address, Javascript. On a session you can record the user_agent on the first page, the ip, the host, and check on the form's action page. Form keys are some number you come up and pass either via url or post, and check on the action pag

[PHP] Re: help condensing regular expressions

2002-04-05 Thread Julio Nobrega Trabalhando
How about: $site_root = '/www/user/htdocs/'; Instead of going relative, go from the root. Or you could put $site_root as your url: $site_root = 'http://www.your_site.com/'; -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinh

[PHP] Re: getting the 'client' date and time for use in PHP scripts ??

2002-04-08 Thread Julio Nobrega Trabalhando
Still you can use Javascript. get it and reload the page appending the info on the url. Or write to a file and open with php. Or you could get what country the user is and calculate the time zones. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei?

[PHP] Re: skipping a WHILE loop in mysql_fetch_*()

2002-04-09 Thread Julio Nobrega Trabalhando
For example: $sql = "SELECT id FROM table WHERE name = '$name'"; $res = mysql_query($sql) or exit (mysql_error()); list ($id) = mysql_fetch_array($res); That's it, use list() to make a variable, from mysql_fetch_array(). Very useful indeed for one line returns :-) More than one column: $sq

[PHP] Re: Sessions and Opera

2002-04-10 Thread Julio Nobrega Trabalhando
Cookies disabled? Or cache? Have you tried a 'fresh' Opera install or a newer version? -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 "Steve Fitzgerald" <[EM

[PHP] Re: Statistic Variables

2002-04-11 Thread Julio Nobrega Trabalhando
Referer page ($HTTP_REFERER), current page (REQUEST_URI), ip ($X_FORWARDED_FOR or $REMOTE_ADDR), host ($HTTP_HOST), time (date() or database's NOW()), username (if you have somekind of authentication), the operating system and browser (from $HTTP_USER_AGENT or similars). These are the ones I lo

Re: [PHP] string...

2002-04-11 Thread Julio Nobrega Trabalhando
Checkout the substr() function. You can do something like: if (substr($var, -9) = '_.jpg')) { // do something } -9 would be the staring position. I am not sure if this is the right number, so you will have to look at the manual :-) -- Julio Nobrega. Um dia eu chego lá: http://sourc

[PHP] Re: unique ID

2002-04-11 Thread Julio Nobrega Trabalhando
Make an autoincrement/primary column? Or keep a number stored and increase it one by one and using when derirable? I prefer the first one :-) -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/w

[PHP] Re: phpMyAdmin protection

2002-04-15 Thread Julio Nobrega Trabalhando
PhpMyadmin now have somekind of authentication method. From the docs: What's the preferred way of making phpMyAdmin secure against evil access? This depends on your system. If you're running a server which cannot be accessed by other people, it's sufficient to use the directory protection bundl

[PHP] Re: placing data outside the server root

2002-04-15 Thread Julio Nobrega Trabalhando
Yes, if the user you are, and are trying to access the dir/files, also have access to them. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 "Andy" <[EMAIL PRO

[PHP] Re: Writing Cross DB application

2002-04-15 Thread Julio Nobrega Trabalhando
There's Metabase, one said to be the most complete of them all, available at http://www.phpclasses.org/ and PearDB, available at http://pear.php.net. I am using Pear, most because it takes advantage of another shared classes from Pear itself. For example, the Log class from Pear can use Pear'

[PHP] Re: PHP Shopping Engine Recommendation

2002-04-15 Thread Julio Nobrega Trabalhando
http://www.oscommerce.com/ -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Que tal um presentinho? http://www.submarino.com.br/wishlistclient.asp?wlid=664176742884 "Robert Collins" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL

[PHP] Re: meta tags from mysql

2002-04-15 Thread Julio Nobrega Trabalhando
Mysql table with a meta column and a url column: $url = $PHP_SELF; $sql = "SELECT meta FROM table WHERE url = '$url'"; Just select from the database a meta column depending on the url people are. -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca Ajudei? Salvei? Qu

[PHP] Re: Removing an Array Element

2001-10-24 Thread Julio Nobrega Trabalhando
>Basically, I just want to know if the Key is set, and if so -- remove it... unset();... -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Jason Caldwell" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > How can I remove an Array Element fro

[PHP] Re: DB wrapper

2001-10-30 Thread Julio Nobrega Trabalhando
There are a few: I use and I believe more in Pear. Metabase is huge. PhpLib, simple but effective. ADODB, nicely done. -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Alberto" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Any1 knows

Re: [PHP] Re: Zipping a folder on a win2000 server with php4.06

2001-10-30 Thread Julio Nobrega Trabalhando
Well, (things are going pretty good, aren't they ;-)) Oh, old Dos memories coming Got it, pkzip was the name: http://www.google.com/search?sourceid=navclient&q=pkzip -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Stefan Rusterholz" <[EMAIL PROTECTED]> wrote

[PHP] Re: Weird caching problem with PHP4/Apache

2001-10-30 Thread Julio Nobrega Trabalhando
These lines will do what you asked, but I am unsure if they will resolve your problem (since I don't know Fatcow and how they configured the server). Anyway, here it is: header ('Expires: Mon, 26 Jul 1997 05:00:00 GMT');// Date in the past header ('Last-Modified: ' . gmdate('D, d M Y H:i:s

[PHP] Re: How do I logout a user ?

2001-11-09 Thread Julio Nobrega Trabalhando
When they click logout, remove the marker from the database that specify they are logged in. Then you must on all pages see if this marker is either 'on' or 'off'. But sessions would be better for this since it is one sql query less. Just unregister the variable on logout and check with: if

Re: [PHP] Cookies, Sessions and Login Proceess

2001-11-12 Thread Julio Nobrega Trabalhando
header(); function is fine. Another option is javascript which is dependent on the client software. But you get the picture about the login process. I just have to agree with Chris, something name 'is_logged' is better than 'accessedbefore'. -- Julio Nobrega A hora está chegando: http://to

[PHP] Re: server side games question

2001-11-13 Thread Julio Nobrega Trabalhando
Hi! For the programming language, I would go with PHP over any other. Yes, yes, there's no best language for every task, but with your C++ background it should be easy to develop advanced techniques on PHP than on others on short time. Depending from what you meant with 'background apps to

[PHP] Re: is_null misses spaces... another solution?

2001-11-13 Thread Julio Nobrega Trabalhando
trim(); it before? -- Julio Nobrega No matter where you go, &this. "Spunk S. Spunk III" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I need to check variables for blank values but it appears that is_null and > =="" return true if there is a space. > > Any

[PHP] Re: keeping my code!

2001-11-14 Thread Julio Nobrega Trabalhando
Here are a few links that might help you: 'Zend Encoder': http://www.zend.com/zend/products.php 'PBC': http://pbc.sourceforge.net/ 'AfterBurner Cache': http://bwcache.bware.it/ Pear's cache classes may also protect a little bit your code... I don't know how easy it is to break the file gener

Re: [PHP] words in a string

2001-11-17 Thread Julio Nobrega Trabalhando
if (ereg('special word', $string)) { echo 'Found'; } else { echo 'Not Found'; } -- Julio Nobrega No matter where you go, &this. <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > hey .. > > i want php to do an IF, when he founds a special word in a stri

[PHP] Re: Dynamic Navigation w/PHP

2001-11-19 Thread Julio Nobrega Trabalhando
Well, I don't really get what is your problem here. :-) You said people must 'enable' pages to have it available. Is it not only a matter of checking this 'enabled' flag? For example a database table with a column named 'enabled', and others 'link' and 'text': (example for mysql)

[PHP] Re: session variables in functions....

2001-11-20 Thread Julio Nobrega Trabalhando
Make it global or pass it as an argument: function CurrentLang(){ global $HTTP_SESSION_VARS; $language = $HTTP_SESSION_VARS["LangID"]; echo($language); } Or: function CurrentLang($HTTP_SESSION_VARS){ $language = $HTTP_SESSION_VARS["LangID"]; echo($language); } --

[PHP] Re: mailing list script?

2001-11-21 Thread Julio Nobrega Trabalhando
Check it out www.hotscripts.com/PHP, under the section 'Scripts and Programs'. You will find a lot of ready to run php scripts that will do exactly what you want... And not what you said you want ;-) -- Julio Nobrega No matter where you go, &this. "Yura" <[EMAIL PROTECTED]> wrote in messa

[PHP] Re: PHP4 & Win2k 'Application Error'

2001-11-21 Thread Julio Nobrega Trabalhando
I had this problem with the CGI installation version. Modify your httpd.conf and adapt it to run PHP as an Apache module and all should work fine. -- Julio Nobrega No matter where you go, &this. "Jason Reid" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > I

[PHP] Re: Forms lose data when going "back" in browser

2001-11-28 Thread Julio Nobrega Trabalhando
Register the submited vars values on a session and echo them inside the value="" part (or similar behavior, selected, checked, etc...) of your form fields. -- Julio Nobrega No matter where you go, &this. "Zavier Sheran" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROT

[PHP] Re: Testing MySQL 4.0 ; detaching queries

2001-11-28 Thread Julio Nobrega Trabalhando
Save the queries on different files, one for each query. Then make a script that will read all these files and execute the queries, maybe run it as a cron job, and delete the succesful ones . With several files will be easier to spot an error if occur, just open it and see the query. Okay, it

Re: [PHP] PHP 4.1 out?

2001-11-28 Thread Julio Nobrega Trabalhando
Mind if I ask why? I do have a few ideas, but I feel I am terribly wrong about them :-) -- Julio Nobrega No matter where you go, &this. "Zeev Suraski" <[EMAIL PROTECTED]> wrote in message 5.1.0.14.2.20011128204245.01e71090@localhost">news:5.1.0.14.2.20011128204245.01e71090@localhost... > And

[PHP] Re: PHP Memory Error

2001-11-29 Thread Julio Nobrega Trabalhando
Used to happen the same here when I was using PhpMyAdmin. On large consults, it would lock. Passing from CGI to module solved all my problems. On the manual you can see the necessary lines to do such. -- Julio Nobrega No matter where you go, &this. "Lallous" <[EMAIL PROTECTED]> wrote in m

[PHP] Re: Need help with a stupid problem!

2001-11-29 Thread Julio Nobrega Trabalhando
Worry not, easier typing: $search .= " ba = '$b'"; If above doesn't satify the needs, maybe you are mysql_escape_string(); it? -- Julio Nobrega No matter where you go, &this. "De Necker Henri" <[EMAIL PROTECTED]> wrote in message 3A8ED7A62794D311AA7700508B6164EC08DCA3E5@SCPTS01">news:3A8

[PHP] Re: Digit Grouping Function

2001-11-29 Thread Julio Nobrega Trabalhando
Function number_format(); should do the trick for you, maybe with the help from str_replace('commas' for 'dots'); -- Julio Nobrega No matter where you go, &this. "Sascha Ragtschaa" <[EMAIL PROTECTED]> wrote in message 7208FD73D511B7040050BF68EF1E027A09@MUCMAIL">news:7208FD73D511B7040

[PHP] Re: database question

2001-11-29 Thread Julio Nobrega Trabalhando
$word = 'bingo'; $sql = "SELECT a_column FROM table WHERE text_column LIKE '%$word%'; $res = mysql_query($sql); // etc... for displaying results Resuming: % on the beggining - doesn't matter what comes before % on the end - doesn't matter what comes after -- Julio Nobrega No matter where

[PHP] Re: foo-bar

2001-11-29 Thread Julio Nobrega Trabalhando
http://info.astrian.net/jargon/terms/f/foo.html Btw, it was just a matter of googleing for 'foo bar origins'. -- Julio Nobrega No matter where you go, &this. "Christoph Starkmann" <[EMAIL PROTECTED]> wrote in message B120D7EC8868D411A63D0050040EDA77111904@XCHANGE">news:B120D7EC8868D411A63D0

[PHP] Re: How to display one line from a file rather than the whole lot

2001-11-30 Thread Julio Nobrega Trabalhando
Dirty trick: http://www.php.net'); while (list ($line_num, $line) = each ($fcontents)) { // echo "Line $line_num: " . htmlspecialchars ($line) . "\n"; if ($line_I_want == $line_num) { $dirty_trick = htmlspecialchars($line); } } echo $dirty_trick; ?> No knowledge of what

Re: [PHP] Speed of Images from DB

2001-11-30 Thread Julio Nobrega Trabalhando
> But that could be due to server capabilities of my ISP (if he has for > example a high tech mysql-server and a relativly slow machine for apache). Probaly :-) From this page: http://www.mysql.com/information/presentations/presentation-oscon2000-27 19/ You can read on section 'Gener

[PHP] Re: I'm getting frustrated with this.

2001-11-30 Thread Julio Nobrega Trabalhando
Well, you could go to www.hotscripts.com/PHP article and tutorials sections. But it is easy. Delete syntax is: This will boom every record. DELETE FROM table; This will boom every Joe: DELETE FROM table WHERE name='Joe'; This will boom an id. That's probaly the way you want. A

[PHP] Re: How to work with MySQL tables WITHOUT telnet, SSH or PhpMyAdmin

2001-11-30 Thread Julio Nobrega Trabalhando
>(I think I need their > assistance if I want to use PhpMyAdmin, right? Most of the time, no. These are the lines you usually need to change on PhpMyAdmin config file: $cfgServers[1]['host'] = 'localhost'; // MySQL hostname $cfgServers[1]['user'] = 'root'; // MySQL user

[PHP] Re: system(), flush() and so on...

2001-11-30 Thread Julio Nobrega Trabalhando
Hi, please be more specific. Including what error you are getting, what is the tools being used, and their versions. Here's a quick help for producing better questions, wich will in turn make us answer faster and with more quality: http://www.tuxedo.org/~esr/faqs/smart-questions.html PS:

[PHP] Re: Duplicating a mySQL row

2001-12-03 Thread Julio Nobrega Trabalhando
I don't know if it is the best but here's an idea: INSERT INTO table SELECT ha, he, hi, ho, hu FROM table LIMIT 1; -- Julio Nobrega Don't eat the yellow snow. "Jim" <[EMAIL PROTECTED]> wrote in message news:p0510100fb8318736de56@[192.168.1.17]... > > What's the best way to duplicate a mysq

Re: [PHP] Re: Duplicating a mySQL row

2001-12-03 Thread Julio Nobrega Trabalhando
Well, I skiped this manual part :-) Maybe the simple select and insert is the simplest form. -- Julio Nobrega Don't eat the yellow snow. "Jim" <[EMAIL PROTECTED]> wrote in message news:p05101010b8318afec141@[192.168.1.17]... > > It appears that this is forbidden ... > > From mysql.com:

[PHP] Re: header("Location:blah...") - passing variables

2001-12-04 Thread Julio Nobrega Trabalhando
You should really try to do it and see if it's possible, before asking on the mailing list... mainly because you will be satisfied with the results... -- Julio Nobrega Don't eat the yellow snow. "Lee Philip Reilly" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTE

Re: [PHP] session in https

2001-12-04 Thread Julio Nobrega Trabalhando
$HTTP_SESSION_VARS shows you this. I don't remember precisely if or where it appears on phpinfo();, but you can try this to see all registered session variables: That's a nice way to see any array, BTW. Including $HTTP_SERVER_VARS, $HTTP_POST_VARS, GET, etc... nice one. -- Julio Nobrega

[PHP] Re: headers

2001-12-05 Thread Julio Nobrega Trabalhando
header("Location: example.php?var=$value"); etc... Or sessions... -- Julio Nobrega Don't eat the yellow snow. "Wilbert Enserink" <[EMAIL PROTECTED]> wrote in message 00e101c17d86$a2c391a0$[EMAIL PROTECTED]">news:00e101c17d86$a2c391a0$[EMAIL PROTECTED]... > Hi all, > > > my q: The results o

[PHP] Re: Multilingual application

2001-12-06 Thread Julio Nobrega Trabalhando
I am using an approach similar to this: $language_file = 'english'; include 'dir/to/languages/'.$language_file.'.inc.php'; on english.inc.php Than you just go echoing the array elements where you want the text to appear. It does require a little bit more of typing but the languages files

[PHP] Re: forms & PHP

2001-12-06 Thread Julio Nobrega Trabalhando
Session would be the easiest thing to use. You could also 'pre-store' the info on a database and retrive it depending at what page users are visiting. -- Julio Nobrega Don't eat the yellow snow. <[EMAIL PROTECTED]> wrote in message BB6D932A42D6D211B4AC0090274EBB1DA0F14F@GLOBAL1">news:BB6D93

[PHP] Re: "trigger" words

2001-12-07 Thread Julio Nobrega Trabalhando
Yes! But since one must learn by trying, I will give you some general rules. Okay, make it work as a function. You need the page url to grab and the word to search. So it's a function with two arguments: function do_it ($page_url , $word) { Then inside the function you fopen() the $page,

[PHP] Get links from a page

2001-12-07 Thread Julio Nobrega Trabalhando
Hi all, I was sure I saw something like this on this list one month ago. But I search for like dozens of word combination to find this post (or anything related to), and was unsuccesful. Anyone has a quick snippet that will scan a bunch of text characters and return the links as an array e

[PHP] Re: The Truth Told!

2001-12-03 Thread Julio Nobrega Trabalhando
> THE INSIDE EDITION I thought it was out there? -- Julio Nobrega Don't eat the yellow snow. <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED]... > EDWARD LAWRENCE STRONG PRESENTS > > THE INSIDE EDITION > >

Re: [PHP] Logo proposal - first thought

2001-12-14 Thread Julio Nobrega Trabalhando
Hey, love the colors! But that's a regular ant. Where's the catch twist exclusive hidden feature? It's an ant, but ain't no ant like other ant :-) I don't know, usually when something common can be found on a design there's a little mod added. Did you draw it? On 1024 video resolution look

[PHP] $PHPSESSID on PHP 4.1.0

2001-12-17 Thread Julio Nobrega Trabalhando
Hi All, I have a few scripts using $PHPSESSID to softly disable cookies requirement on some pages. I just installed PHP 4.1.0 and I am porting some lines to adapt to the new version. If I do this: It doesn't show nothing at all. Did something changed, does this var now have a new nam

[PHP] Re: $PHPSESSID on PHP 4.1.0

2001-12-18 Thread Julio Nobrega Trabalhando
Hi again, Here are a few updates (error_reporting(E_ALL)): $_SESSION['PHPSESSID']; // Undefined index PHPSESSID error // Doesn't work. Not even a undefined variable. // echo $SID doesn't either But: echo session_id(); // works! Thanks Andrey for the remainder, but session were already

Re: Re: [PHP] Passing through Array's to another script

2001-12-18 Thread Julio Nobrega Trabalhando
Well, there's a small difference between form's GET/POST and passing variables using the ? on urls. I don't know the techinal details of it, but it's possible. I guess, on this particular case, the form method is POST. When the next page is loaded (the action target), you put some GET parameters

Re: [PHP] Passing through Array's to another script

2001-12-18 Thread Julio Nobrega Trabalhando
> However, you can't do this: > > > > Because a & b won't get submitted. Well, like I said, I don't understand very well, but things after the ? are available on the action page, even if the method is POST. Here's a tested example (PHP 4.1.0, Win2k AS, Apache 1.13.20) aaa.php: bbb.php

Re: [PHP] Re: $PHPSESSID on PHP 4.1.0

2001-12-18 Thread Julio Nobrega Trabalhando
Yes, I know. But the problem is PHP 4.1.0, or maybe something on the new php.ini that comes with. My scripts were echo'ing $PHPSESSID fine before it. -- Julio Nobrega. Um dia eu chego la: http://sourceforge.net/projects/toca "Andrey Hristov" <[EMAIL PROTECTED]> wrote in message 032e01c187db$

Re: [PHP] Re: $PHPSESSID on PHP 4.1.0

2001-12-18 Thread Julio Nobrega Trabalhando
Yes! That's it. I was accessing vars using new methods, but I forgot $PHPSESSID was supposed to have globals on. So simple, yet I have flooded the list with messages. Thanks Andrey, I think it's better next time look at all possible options ;-) -- Julio Nobrega. Um dia eu chego la: http://

[PHP] One good thing about $_SESSION

2001-12-26 Thread Julio Nobrega Trabalhando
Is that while porting a script to PHP 4.1.0, where I used to check: if (session_is_registered('del_power') && $del_power == 1) { // del stuff } Because $del_power could be registered as 1 or 0, now I can do: if ($_SESSION['del_power'] == 1) { // del stuff } Nice. Less typing and

Re: [PHP] One good thing about $_SESSION

2001-12-26 Thread Julio Nobrega Trabalhando
Yes, but I just thought of doing this way when porting :-)) PS: (Not 100% true, there's the question of $_SESSION being global now. Makes life easier too :-)) -- Julio Nobrega. Um dia eu chego lá: http://sourceforge.net/projects/toca -- PHP General Mailing List (http://www.php.net/) To

[PHP] Re: Maintaining a session without cookies

2001-08-24 Thread Julio Nobrega Trabalhando
Append the session id on the url. There are several ways to do this. Change all urls to put it at the end, add a javascript that will do it for you (saw at php.net's page). Or change an option at php.ini to this also automatically for you, or use ini_set(); if you can't change the .ini. --

[PHP] Re: PHP secure

2001-08-24 Thread Julio Nobrega Trabalhando
Encode (or compile) the source. Zend's compiler costs 2400 dollars. At this cost is better to release your code on an open source license ;-) -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Peter Allum" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL

Re: [PHP] The future of PHP

2001-08-27 Thread Julio Nobrega Trabalhando
Hi Manuel, Great post. I enjoyed the part where you said it would be a good idea to do some 'competition' with php programmers, sponsored by some company. For example, most times when I want a php script, either I go to Hotscripts.com or Sourceforge.net. Sf.net, by rebound, makes me rem

[PHP] Re: Thinking about going to ASP

2001-08-27 Thread Julio Nobrega Trabalhando
How about Mono from Ximian? -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Reductor" <[EMAIL PROTECTED]> wrote in message 008001c12df9$e96806e0$eb00a8c0@mum">news:008001c12df9$e96806e0$eb00a8c0@mum... > Just looking over the achives of the .net show(was msdn show), and wi

Re: [PHP] Re: Thinking about going to ASP

2001-08-27 Thread Julio Nobrega Trabalhando
ws:003901c12ef8$fd9a4ec0$eb00a8c0@mum... Mind giving some more infro on this :D ?!? - Original Message ----- From: "Julio Nobrega Trabalhando" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, August 27, 2001 10:36 PM Subject: [PHP] Re: Thinking about going to ASP &g

[PHP] Re: Last Modified question..

2001-08-28 Thread Julio Nobrega Trabalhando
Well, you could change just to look at this. Use php's functions to change, check the last modified, and change it back. Should take a few micro-seconds ;-) and it only uses php. -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Jay Paulson" <[EMAIL PROTECTED]> wrote in

[PHP] Non selected submited form-array values

2001-08-30 Thread Julio Nobrega Trabalhando
Hi All, I already spent too much time trying to solve this one by myself, so I am in need of a little bit of help. I have a form with checkboxes, all with the same name (name="noticias[]"). When it is submited, only the selected checkboxes become a value on the array $noticias on the next

[PHP] Delete files older than X seconds.

2001-08-30 Thread Julio Nobrega Trabalhando
Hi All, Another doubt. How can I delete files older than X seconds from a given folder? At the on-line manual I could only find a contributed note about 'discover time of last modification' from a file under a folder. Any help is appreciated. -- Julio Nobrega A hora está chegando: ht

Re: [PHP] coding practices

2001-09-15 Thread Julio Nobrega Trabalhando
I am the type of guy that sits and code. But now I am working on a company where we sell systems to large financial entities. So, I have now to make 'prettier' stuff for high executives understand. -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Ninety-Nine Ways To Die" <[

[PHP] Re: include XHTML document

2001-09-24 Thread Julio Nobrega Trabalhando
echo ' xml version="1.0" encoding="iso-8859-1"?> That's how I am putting my XHTML on SF. -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Cweiske" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Hi > > I wrote my new page in XHTML 1.0, s

Re: [PHP] PHP isn't reading the php.ini

2001-09-24 Thread Julio Nobrega Trabalhando
Sometimes I have to add the 'extensions' word: extension=extensions/php_mssql.dll -- Julio Nobrega A hora está chegando: http://toca.sourceforge.net "Mark Roedel" <[EMAIL PROTECTED]> wrote in message [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > -Original Message- > From: Brandon Or

<    1   2