• Member Avatar for broj1
    broj1

    Replied To a Post in mysql_query() expects parameter 1 to be string, resource given

    The error is in the paramaters of the `mysql_query` function. The first parameter should be the query (string type), and the second (optional) parameter is the link (of type resource …
  • Member Avatar for broj1
    broj1

    Replied To a Post in send data to users folder

    Do you already have an upload form? If not, you can find nice tutorial [here](http://www.tizag.com/phpT/fileupload.php). Make sure that everything is happening within the restricted area (i.e. a user has to …
  • Member Avatar for broj1
    broj1

    Began Watching send data to users folder

    i am trying to create a site, when user create his account then make automatic his directory with his name. when he wants to upload his photos, these photos go …
  • Member Avatar for broj1
    broj1

    Replied To a Post in send data to users folder

    And what is the actual problem? Describe where you got stuck and post possible error messages.
  • Member Avatar for broj1
    broj1

    Began Watching Error displaying multiple photos

    I am trying to save 2 photos to my MySQL database. I can only see one of the 2 photos in the database (i.e. its name) but I see the …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Error displaying multiple photos

    The problem might be occuring at the time of saving pictures in the database (there are two photos in the folder but only one in the database). Post the code …
  • Member Avatar for broj1
    broj1

    Gave Reputation to lps in errors in inbox.php

    Agreed with @broj1 where your $topuid is probably not defined as an array. And the cause is actually can be found easily by paste the error to google. Here is …
  • Member Avatar for broj1
    broj1

    Replied To a Post in errors in inbox.php

    > Here is what I do: echo implode(', ', (array)$topuid);, with this code, the $topuid will be cast into an array for implode. Casting is a good idea. You also …
  • Member Avatar for broj1
    broj1

    Stopped Watching JSON Array Errors

    I'm not able to get the content of this array, please can someone help? Where Am I getting it wrong? Below is the code $barcode = "9780980200447"; function parseInfo($barcode) { …
  • Member Avatar for broj1
    broj1

    Began Watching errors in inbox.php

    Hi im getting this error on inobox.php any ideas please Warning: implode(): Invalid arguments passed in /home/jktempla/public_html/SCRIPTS/DATINGSCRIPT/inbox.php on line 199 <?php // Fetch user random for display on bottom <THIS …
  • Member Avatar for broj1
    broj1

    Replied To a Post in errors in inbox.php

    It seems that the `$topuid` variable is not an array (the implde function expects an array). Can you check it out? You can put this code just before line 3 …
  • Member Avatar for broj1
    broj1

    Replied To a Post in JSON Array Errors

    You are welcome. Please mark as solved if no more questions. Happy coding.
  • Member Avatar for broj1
    broj1

    Began Watching How to get a loop count for each row in while loop

    I have a gallery in grid. For eg: https://encrypted-tbn0.gstatic.com/images?q=tbn:ANd9GcSegNVXMSnTRzHETnAjZXCd6siwHQysMXc_jp1OyiSDie2_9jhsIg Each row can cont max of 4 images. I have written while loop. i want to get the total count of …
  • Member Avatar for broj1
    broj1

    Replied To a Post in How to get a loop count for each row in while loop

    You can store number of images per row in an array (this is untested, just a concept): // between lines 17 and 18 - initialize variables $rowNo = 1; $imagePerRow …
  • Member Avatar for broj1
    broj1

    Replied To a Post in JSON Array Errors

    Your array has two main elements: 1. settings - an array of common settings 2. books - an array of book data (each element here contains the same book data) …
  • Member Avatar for broj1
    broj1

    Replied To a Post in JSON Array Errors

    So where did you get stuck? I managed to access any element of the above array.
  • Member Avatar for broj1
    broj1

    Gave Reputation to cereal in JSON Array Errors

    In addition: `$values['books']` is an array where the index key is the `book_id`, for example: [books] => Array ( [38] => Array ( [book_id] => 38 [title] => Alexander of …
  • Member Avatar for broj1
    broj1

    Began Watching JSON Array Errors

    I'm not able to get the content of this array, please can someone help? Where Am I getting it wrong? Below is the code $barcode = "9780980200447"; function parseInfo($barcode) { …
  • Member Avatar for broj1
    broj1

    Replied To a Post in JSON Array Errors

    The values you are trying to display have no values so you see nothing. To prove that add some static texts to the echo statement, like this: foreach ($array as …
  • Member Avatar for broj1
    broj1

    Stopped Watching insert error in description

    $descrr = "Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown …
  • Member Avatar for broj1
    broj1

    Began Watching insert error in description

    $descrr = "Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown …
  • Member Avatar for broj1
    broj1

    Replied To a Post in insert error in description

    Your text contains an apostrophe (`'`) which is also used in mysql as a string delimiter. In order to store an apostrophe into the DB you have to escape it …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Catchable fatal error

    It is not clear what the `coupon` class is expected to do. It seems that there is some code missing. The only method defined in it is the `Voucher` method. …
  • Member Avatar for broj1
    broj1

    Began Watching Catchable fatal error

    i have continued my developing my code on e-commerce website to grant the discount to client on basis of coupon code entered <?php /** * Consider and apply voucher codes …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Catchable fatal error

    On line 14 you are calling the `Voucher` method which expects two parameters: the object of the `Registry` class (first parameter) and the voucher code (second parameter). You supplied only …
  • Member Avatar for broj1
    broj1

    Stopped Watching cross checking the codes from database

    hello every one i have one small doubt i have the following code i want the user to enter the coupon code which has been randomly generated and saved in …
  • Member Avatar for broj1
    broj1

    Replied To a Post in cross checking the codes from database

    You are welcome. Please mark the thread as solved if no more questions. Happy coding :-)
  • Member Avatar for broj1
    broj1

    Replied To a Post in cross checking the codes from database

    Sorry, my typo. Line 22 of my code should be: if($result->num_rows != 0) { ... (no parentheses after the `num_rows`). Also change the action of the form to the same …
  • Member Avatar for broj1
    broj1

    Began Watching cross checking the codes from database

    hello every one i have one small doubt i have the following code i want the user to enter the coupon code which has been randomly generated and saved in …
  • Member Avatar for broj1
    broj1

    Replied To a Post in cross checking the codes from database

    You are mixing `mysql_*` and `mysqli_*` functions as well as object oriented and procedural style. The code below is `mysqli_*` OOP style, and is not tested, just to give you …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Need a help in php language

    Please mark the thread as solved if no more questions. And yes, do not use deprecated mysql_* functions in production. Happy coding.
  • Member Avatar for broj1
    broj1

    Stopped Watching php show ad on every 10th ticket

    Hello i want to make to show adds but on every 10th ticket i have tried with for loop but its adding too much adds here is the code: if($is_active …
  • Member Avatar for broj1
    broj1

    Replied To a Post in An index.php Question

    There are errors in your code above: Line 199 - missing `;` at the end of the line: echo $state Line 229 - missing a statement (or at least `;`) …
  • Member Avatar for broj1
    broj1

    Replied To a Post in An index.php Question

    Maybe your hosting provider does not allow displaying of errors. Check in web hosting control panel if there is any php or apache error logging. There is quite a lot …
  • Member Avatar for broj1
    broj1

    Replied To a Post in An index.php Question

    It loads index.php in my browser but shows nothing. Can you post the code? Have you tried error reporting?
  • Member Avatar for broj1
    broj1

    Replied To a Post in An index.php Question

    Cool. PHP works. You do not have to understand all the info for now :-). Maybe you post the contents of the index.php. You might have some errors in it. …
  • Member Avatar for broj1
    broj1

    Replied To a Post in An index.php Question

    You can run .php in a browser if the server supports it. If it is on a web hosting server, your provider have to support it (and I guess most …
  • Member Avatar for broj1
    broj1

    Began Watching Question Please concerning php

    is there any way to access the variables of this function outside ? public function selectData($table, $where = null, $wheree = null, $where1 = null, $wheree1 = null) { $QUERY …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Question Please concerning php

    Please post the whole class structure not only one method. $Fetch_Assoc, $Fetch_Array, $Num_Rows and $Fetch_Object should be either assigned to some properties or somehow returned by the function. There is …
  • Member Avatar for broj1
    broj1

    Replied To a Post in An index.php Question

    > Yes, my index page contains PHP code already (but has a .html extension) OK, so change it to index.php. It should display html + php script output. If not, …
  • Member Avatar for broj1
    broj1

    Replied To a Post in php show ad on every 10th ticket

    I am not sure if I understood you right, but I'll give it a go. Firstly I think you do not need a `$count` variable since you have `$i` for …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Need a help in php language

    I hope you din not just copy the code above since it is just a guess (and also contains a typo) - it won't work. Please post the code for …
  • Member Avatar for broj1
    broj1

    Began Watching php show ad on every 10th ticket

    Hello i want to make to show adds but on every 10th ticket i have tried with for loop but its adding too much adds here is the code: if($is_active …
  • Member Avatar for broj1
    broj1

    Replied To a Post in php show ad on every 10th ticket

    Your for loop gets repeated only two times. Did you mean you want to display an ad every 10th match?
  • Member Avatar for broj1
    broj1

    Began Watching Need a help in php language

    I tried to get some data from my function but I couldn't, Can any one help me I have some data in functions file, from this page into my index …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Need a help in php language

    I presume $user is the object instatntiated from the class that contains the selectData method. I am guessing that this class stores the results (array, object...) into some properties. Now, …
  • Member Avatar for broj1
    broj1

    Began Watching An index.php Question

    I am working on a project and have been doing some research. One thing I have noticed are tutorials calling for saving the index file in .php. I tried this …
  • Member Avatar for broj1
    broj1

    Replied To a Post in An index.php Question

    Te index file should have a php extension only if you have some PHP code in it. Also your web server should have all the neccessary modules instaled and enabled. …
  • Member Avatar for broj1
    broj1

    Began Watching Your Favourite IDE or Editor for PHP

    Hi All, Been messing about as usual and managed to trash my long suffering laptop. Luckily all my data is backed up and it was a simple matter of SugarSyncing …
  • Member Avatar for broj1
    broj1

    Replied To a Post in Your Favourite IDE or Editor for PHP

    I've been a long time Eclipse user. Not very advanced usage though, there are still things that I don't quite understand or like. But I like the fact that I …

The End.