Search Results

Showing results 1 to 40 of 68
Search took 0.01 seconds.
Search: Posts Made By: JRSofty
Forum: PHP Apr 15th, 2009
Replies: 11
Views: 1,283
Posted By JRSofty
The problem could also be with your regular expression.

I take it you are trying to make it more dynamic allowing someone to define the regex using the variable $URLSearchString.

Since I...
Forum: PHP Apr 15th, 2009
Replies: 11
Views: 1,283
Posted By JRSofty
That is because you are using $1 and $2 instead of \\1 and \\2 for the call backs.

$1 and $2 mean nothing.
Forum: PHP Apr 15th, 2009
Replies: 8
Views: 309
Posted By JRSofty
Ok so your basic choices here are as follows:

1. Use javascript to add the values to the update link whenever they are edited (not an easy feat).
2. Use a proper form to post the information. A...
Forum: PHP Apr 15th, 2009
Replies: 11
Views: 1,283
Posted By JRSofty
It could be because you are using the wrong call back for the preg_replace.

Here's how I've done it in the past:

while(preg_match("#\[url=([^\]]+)\](.+?)\[/url\]#ies",$articledata)){
...
Forum: PHP Apr 15th, 2009
Replies: 27
Views: 1,089
Posted By JRSofty
I'm a user of CrimsonEditor. It's pretty simple but I find it is quite good for what I need it to do. There are tons of syntax highlighting editors out there. I would suggest finding one that you...
Forum: PHP Apr 15th, 2009
Replies: 8
Views: 309
Posted By JRSofty
Can we see the HTML you are using to build your form? This might clue us in on what exactly you are trying to do.

If you are trying to get a link on a form to act like a button then you can add a...
Forum: PHP Apr 15th, 2009
Replies: 5
Views: 528
Posted By JRSofty
Designer there is no need for the ; in the httpd.conf file.

However I do see another inconsistency that might be the problem. You're PHPIniDir statement uses the typical windows slash \ when it...
Forum: PHP Apr 15th, 2009
Replies: 3
Solved: Php query help
Views: 370
Posted By JRSofty
Hi Rajeesh,

What you are attempting to do is kind of like producing a dynamic SQL statement. Actually it's not as hard as it seems and you are on the right path.

Basically you should start with...
Forum: ASP Apr 15th, 2009
Replies: 0
Views: 176
Posted By JRSofty
So I decided that I would describe my attempts at developing my own Rapid Development Framework, here on DaniWeb since they are so nice to give people free blog space.

So many of you are probably...
Forum: PHP Apr 14th, 2009
Replies: 7
Views: 399
Posted By JRSofty
Your code is absolutely not safe! Why? Because you didn't check the user input to make sure it is clean. You are setting yourself up for an SQL injection.

To help fix this at the very minimum you...
Forum: PHP Apr 14th, 2009
Replies: 4
Views: 1,607
Posted By JRSofty
Here's a bit of code that might help:


<?php

function recurseDir($dir){
if(is_dir($dir)){
if($dh = opendir($dir){
while(($file = readdir($dh)) !== false){
if($file...
Forum: PHP Apr 14th, 2009
Replies: 3
Views: 803
Posted By JRSofty
You have stored the image as some sort of Binary Large Object (BLOB) and want to return it to a browser as a file?

Just want to make sure I understand the problem before I explain how to do this.
Forum: PHP Apr 14th, 2009
Replies: 1
Views: 217
Posted By JRSofty
You are looking for a Rich Text Editor? This is not normally handled by PHP directly but through Javascript.

A couple I can think of off the top of my head:
http://freerichtexteditor.com/...
Forum: PHP Apr 14th, 2009
Replies: 2
Views: 286
Posted By JRSofty
You don't have to write the function twice to call it twice, once is enough. Try something like this:


<?php
function encode5t($password)
{
$ret = $password;
for($i=0;...
Forum: PHP May 14th, 2008
Replies: 16
Views: 4,233
Posted By JRSofty
His problem is quite simple actually. Here's his original code
$name=$_POST['name']; //from the name form
$q_id=$_GET['id'];
$sql="INSERT INTO...
Forum: PHP Mar 18th, 2008
Replies: 3
Views: 666
Posted By JRSofty
Is this for a local test system or are you deploying this to real world?
Forum: PHP Mar 18th, 2008
Replies: 11
Views: 2,369
Posted By JRSofty
Well the warning for mkdir could be a problem. What version of PHP are you running? Can you give me a link to a phpinfo(); function?

Never mind the above you must be using PHP 4. The recursive...
Forum: PHP Mar 18th, 2008
Replies: 3
Views: 956
Posted By JRSofty
Also any characters (even null or whitespace) before the opening <?php tag can also cause this error so make sure that your <?php starts at the very first line and column of your script.

In...
Forum: PHP Mar 18th, 2008
Replies: 11
Views: 2,369
Posted By JRSofty
Try to add this at the beginning of your code

ini_set("error_reporting","E_ALL");


Then run your code and see if there are any errors that display.
Forum: PHP Mar 18th, 2008
Replies: 1
Views: 1,670
Posted By JRSofty
There's no built-in functions exactly for what you want to do so what you need to do is build some code of your own.

First take a look at the date/time functions of PHP...
Forum: Geeks' Lounge Mar 17th, 2008
Replies: 148
Views: 13,789
Posted By JRSofty
Forum: PHP Mar 17th, 2008
Replies: 5
Views: 1,359
Posted By JRSofty
The reason you are getting the error is because mysql sent back an error instead of a result. Most likely there is something in your SQL statement that has caused a problem.

What the best thing to...
Forum: PHP Mar 14th, 2008
Replies: 4
Views: 2,441
Posted By JRSofty
Hmm yes that is much more efficient than the way I'm doing it.

I'll give it a shot thanks for the help.
Forum: PHP Mar 14th, 2008
Replies: 8
Views: 837
Posted By JRSofty
Nevermind what I said do what Petr.Pavel says :D
Forum: PHP Mar 14th, 2008
Replies: 4
Views: 627
Posted By JRSofty
The main reason you can't find it is that the output is not very clean. No newlines no indentions, in a lot of cases just code. This could be because of the software you are using and how they do...
Forum: Geeks' Lounge Mar 14th, 2008
Replies: 148
Views: 13,789
Posted By JRSofty
[I think I can .. I think I can .. I think I can ..]
Forum: PHP Mar 14th, 2008
Replies: 11
Views: 2,369
Posted By JRSofty
What is the value of $semname?

Is it a complete path or just a relative one?
Forum: PHP Mar 14th, 2008
Replies: 4
Views: 627
Posted By JRSofty
Although this is a PHP forum and your problem is HTML I'll give you the answer as I see it ;)

At the bottom of your forum you have a small dropdown box that allows you to jump around to different...
Forum: PHP Mar 14th, 2008
Replies: 10
Views: 1,870
Posted By JRSofty
Don't forget to mark this solved!
Forum: PHP Mar 14th, 2008
Replies: 4
Views: 2,441
Posted By JRSofty
Ah well you see the config array needs to be read from the database. This is because that each module will have its own configuration. I could very well write things like
$config = array(
...
Forum: PHP Mar 14th, 2008
Replies: 10
Views: 1,870
Posted By JRSofty
Yep you don't have a proper condition and so overwriting your value.
Try something like this:

$qry = "select cena from albumy where EAN_kod='$EAN_kod'";
$result = mysql_query($qry);...
Forum: PHP Mar 14th, 2008
Replies: 11
Views: 2,369
Posted By JRSofty
Do you get any errors besides the fact that the index.php file is not created?
Forum: PHP Mar 14th, 2008
Replies: 10
Views: 1,870
Posted By JRSofty
Where do you do a query on table ciste_media? I don't see that in your code. All I see is from the albumy table and as I stated before you need to fix the check for rows in your result from the...
Forum: PHP Mar 14th, 2008
Replies: 6
Views: 569
Posted By JRSofty
I would say it is a hiddeous idea honestly. This because what if there are references to the user_id in other tables? Then you would have to go through all these tables and update them to match the...
Forum: PHP Mar 14th, 2008
Replies: 6
Views: 708
Posted By JRSofty
Another question is are you attempting this from your own computer or are you working on a hosted server?

If you are using a hosted server and they don't provide you with PHP then you won't be...
Forum: PHP Mar 14th, 2008
Replies: 10
Views: 1,870
Posted By JRSofty
Most likely your error comes from this point right here:
if (mysql_num_rows($result) >= 1)
{
$cena_polozky = mysql_result($result, 0, "cena");
$cena +=$cena_polozky*$qty;
}
}
}
return $cena;...
Forum: PHP Mar 14th, 2008
Replies: 4
Views: 2,441
Posted By JRSofty
Hi everyone,

I'm a lazy programmer and when I want to create an array that I can store serialized in a database I don't feel like typing out all the array stuff rather I want to use a delimited...
Forum: PHP Mar 14th, 2008
Replies: 10
Views: 1,870
Posted By JRSofty
Just because the result is valid does not mean that there are rows.

It would be better to check if the result contains rows before attempting to jump to a particular one. For example ...
Forum: PHP Mar 5th, 2008
Replies: 10
Views: 1,072
Posted By JRSofty
You can use Javascript to check if the text boxes actually have data, OR you can use PHP, OR you could use both.

My #1 rule when dealing with user input is that I always always always check that...
Forum: PHP Mar 5th, 2008
Replies: 12
Views: 1,489
Posted By JRSofty
You'll need some sort of join to make this happen. You are attempting to get data from two different tables.

Is there data in the employer table like an ID that is placed into the post_resume...
Showing results 1 to 40 of 68

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC