81 Posted Topics

Member Avatar for Scottmandoo

Hi Scottmandoo, best if you place this at the top and run it: [code=php] ini_set("display_errors", true); error_reporting(255); [/code] Then you could post the error messages and I'll explain what they mean. Also, could you please edit your post and add "=php" into the tag code (code=php)? It will tell this …

Member Avatar for Scottmandoo
0
245
Member Avatar for sukhy_1

Hi there, I'm a bit confused: [LIST] [*] I don't see a reason for calling [icode]session_start(); session_destroy();[/icode] I'd say that you can safely ignore this [*] The other "Put this code in first line of web page" is correct though. All your protected web pages must have .php extension and …

Member Avatar for petr.pavel
0
104
Member Avatar for sukhy_1

Hi Sukhy, your post looks more like a project specification then a problem description. If you want me to program this thing for you, I'll do it for 40 USD per hour. I would give you price estimation after we would get together some proper specs. If you have some …

Member Avatar for nav33n
0
125
Member Avatar for mcx76

Hi there, are you running the server yourself? I mean if you're on a normal commercial hosting you're not allowed to modify php.ini. You cannot create your own php.ini - only one php.ini is The One. If you are running your own server then maybe you have modified wrong php.ini. …

Member Avatar for Suomedia
0
286
Member Avatar for shezz

Hi Shezz, so you run savevote.php and it still won't save the vote, right? Does it show any error message? The script makes sure that you vote only once so perhaps that's why - you're trying to vote more than once. Or maybe DOMDocument isn't supported in your PHP installation. …

Member Avatar for petr.pavel
0
56
Member Avatar for pedward

Hi there, the key is this line in your CSS: [icode].unit-rating li a:hover[/icode] You cover the other A's with the active A. Change z-index:20; to say 10 and it will show below not over them. (tested in Firefox) The number is off the box because it is right aligned while …

Member Avatar for petr.pavel
0
107
Member Avatar for kevin wood

Hi Kevin, the basic question: do you store the images in a database or as files in a file system. Also, what should I imagine when you say "the variable name which was set for the images"?

Member Avatar for kevin wood
0
107
Member Avatar for anasta

Hi Anasta, I must be missing something because to me, the answer is very simple: [code=php] ... echo '<form action="saveme.php">'; echo "<tr>"; echo '<td><input type="checkbox" name="gameId" value="'.$row['id'].'"></td>'; echo "<td width='25' align='center'>" . $row['game'] . "</td>"; echo "<td width='150'>" . $row['home'] . "</td>"; echo "<td width='150'>" . $row['away'] . "</td>"; echo …

Member Avatar for petr.pavel
0
167
Member Avatar for JRSofty

Hi JRSofty, before I think about a solution to what you want, let me cast some doubts on it first: Is it really so time saving to have your config code instead of good ol' php? [code=php] $config = array( "access" => array( 'read' => array(1,2,3), 'write' => array(1,2), 'modify' …

Member Avatar for JRSofty
0
174
Member Avatar for dwlamb_001

Hi there, 2003 is "can't connect to MySQL server" right? I don't think that just restoring the files did the magic - if you didn't previously delete them in the first place :-) desktop.err is error log (your computer is called "desktop") desktop.pid is socket number where MySQL is connected …

Member Avatar for petr.pavel
0
88
Member Avatar for vijukumar

Hi vijukumar, just because you press a button, nothing is going to be executed unless you program a script that does it (connect to a database, build the UPDATE query from FORM values and executes the query against the database). Maybe you're using some framework that does it for you …

Member Avatar for petr.pavel
0
110
Member Avatar for joker40

I agree with silviuks that generally, what you want isn't a good idea :-) I'm not sure if what you are after is to fill blanks in a row of user_ids. What if you have three users: 1, 2, 3 and delete 2. Do you want the next new user …

Member Avatar for JRSofty
0
100
Member Avatar for jino

I agree with forzadraco: don't do this. An attacker could simply call your page with: page.php?string=;DELETE * FROM yourtable and you're dead. However, to answer your question, the function you're looking for is urlencode().

Member Avatar for jino
0
100
Member Avatar for flaco

Hi Flaco, it looks to me like you didn't edit includes/config.php to enter MySQL login information. So go to your Control panel, find out the database name, user name and password and fill it in there. You may have to create the database first, most web hostings don't create one …

Member Avatar for petr.pavel
0
76
Member Avatar for davelandon

Hi Dave, you're not giving us the whole script, are you? $sendmail should be defined somewhere. That's where your path to sendmail goes. BTW: This method of sending e-mails is bad, read something about e-mail injection: [url]http://en.wikipedia.org/wiki/Email_injection[/url] If you you're still having problems with sending through sendmail (it could be …

Member Avatar for davelandon
0
133
Member Avatar for dami06

Hi Dami, I'm sorry but I didn't understand :-) Correct me if I'm wrong please: - you have three types of users: students, tutors and admins - each of the users should see different menu - everything works ok except for the menu: all users see the same - students' …

Member Avatar for petr.pavel
0
320
Member Avatar for ZenMartian

Hi Keith, I'm afraid you'll have to attach the two scripts that you're using :-) I'll have a look then and hack them together if it's not too much work.

Member Avatar for petr.pavel
0
131
Member Avatar for nishanthaMe

Hi nishanthaMe, this is a last-hope advice. I found on Wikipedia that Wikipedia itself uses this algorithm: [url]http://en.wikipedia.org/wiki/Boyer%E2%80%93Moore_string_search_algorithm[/url] So you could download Wikipedia source code and find it in there.

Member Avatar for petr.pavel
0
86
Member Avatar for coffeepot!

Hi John, I'm reluctant to believe you on the spaces issue with readdir(). I checked the manual and nobody in the discussion has ever mentioned it. Maybe you think that it skips the files but in fact, something else down the road in your script does. Anyways, try using glob() …

Member Avatar for petr.pavel
0
120
Member Avatar for BenR41

I do realize this was a fake post and an advertisement (judging from the snipped signature) but I'd like to add my five cents anyway, because the method described above is pretty crude. An easy and elegant method is: [code=php] include dirname(__FILE__)."/ws8_extensions.php"; include dirname(__FILE__)."/ws8_functions.php"; [/code] BTW: Thanks for removing the …

Member Avatar for petr.pavel
0
82
Member Avatar for Inny

Hi Inny, read the whole reply to find the error at its end. I'll keep the rest of my original post to show you my track of thoughts which could be helpful for you some other time. Maybe fopen wrappers aren't enabled. (file('http://...) Or maybe short_open_tag is off. (<?php versus …

Member Avatar for Inny
0
134
Member Avatar for satimis

Hi Satimis, let me ask you a couple of questions first: 1) are you looking for a general way to find a RSS channel for any website? There isn't any. It's the people who run the website who can create a RSS channel and make it available for their readers. …

Member Avatar for petr.pavel
0
179
Member Avatar for mexaros

Hi Mexaros, maybe you're linking to a remote site for web stats or some cool gadget. I would probably search all files for "http". Internal links don't need to have http (use absolute or relative paths) so this search should discover external links. You could also use an extension like …

Member Avatar for petr.pavel
0
112
Member Avatar for lydia21

Hi Lydia, I guess that you're calling mail_attachment() with wrong information in $attachment parameter. You're passing url while it should be a full path in the server's file system. E.g. /var/www/vhosts/website.com/httpdocs/profiles/resumes/.... or ./profiles/resumes.... You have to find out yourself what the path is (I don't know where your calling script …

Member Avatar for petr.pavel
0
205
Member Avatar for stalk

I can translate for you, pal :-) I'm Czech too. (Můžu ti překládat, jsem taky Čech.) We need to know of what type the return values are: arrays or objects? (Potřebujeme vědět, jakého typu jsou návratové hodnoty těch funkcí: pole nebo objekty?)

Member Avatar for petr.pavel
0
75
Member Avatar for chrisw09

Hi Chris, to know for sure you'll probably have to do some measurement. I recommend reading about ANALYZE (to do the measurements right is a kind of a science). For basic PHP measurement you can use $start = time() at then $length = time()-$start. But for real work I recommend …

Member Avatar for forzadraco
0
1K
Member Avatar for dami06

Uhm, are you talking about syntax highlighting? Try highlight_string() - but it's just for PHP source code. If you want more languages then grab some open source library like [url]http://www.pear.php.net/package/Text_Highlighter[/url] or [url]http://www.phpclasses.org/browse/package/3293.html[/url] Some related info: [url]http://www.sitepoint.com/article/highlight-source-code-php[/url]

Member Avatar for petr.pavel
0
75
Member Avatar for Fasola

Hi Fasola, this is a specification for a project not a list of three problems :-) I could program this for you for USD 200 if you want. Update: Oops, I just noticed that Code 5 System is for .NET, you got wrong forum. I can't help you with that. …

Member Avatar for petr.pavel
0
119
Member Avatar for myth3_16

Hi there, I assume you want to reorder the list just because you don't know of a better method of pre-selecting an option, right? If that's so I suggest using "selected" instead: [code=php] $pageTitle = 'Day You Were Married'; // this is for testing, I expect this variable to be …

Member Avatar for petr.pavel
0
102
Member Avatar for nick1981

Hi Nick, it's a bit difficult to debug your script when you didn't use the syntax highlighting provided by this forum. Could you please edit your post insert the CODE tags? Could I see the script at work somewhere? In general, the problem is either in HTML (answers are overwriting …

Member Avatar for petr.pavel
0
108
Member Avatar for cancer10

Hi there, try something along these lines: [code=sql] SELECT columnName, ABS(columnName - 9) AS distance ORDER BY distance LIMIT 1 [/code] Could be that ORDER BY won't accept alias distance in which case you'll have to repeat the ABS() code. The trick is in calculating the distance of your number …

Member Avatar for petr.pavel
0
118

The End.