• Member Avatar for cereal
    cereal

    Gave Reputation to Dani in Zend PHP Studio won't open

    I downloaded the .dmg file for OS X, dragged and dropped the application into the Applications folder, and then attempted to open the application. It just kept resulting in that …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Mailer Error: Could not instantiate mail function.

    Okay, you set up `admin@web.com` in the FROM header, but the authentication is failing. Is this the account that is authenticating to the SMTP server? From the log it seems …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Zend PHP Studio won't open

    Hi Dani, hope you're doing well, try to send the report to studio-feedback@zend.com or to their forums http://forums.zend.com and see if they can help. It seems related to Zend, if …
  • Member Avatar for cereal
    cereal

    Began Watching Zend PHP Studio won't open

    I have a one day old Macbook Pro. I tried to install PHP Zend Studio (which is what I use to code in). Everytime I try to run it for …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Mailer Error: Could not instantiate mail function.

    Ops! My fault, I confused `error_log()` with `file_put_contents()` syntax :D Sorry, please replace the error log line with: error_log(sprintf("(%s) %s\r\n", $level, $message), 3, $log_file); And it should work fine. > …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Mailer Error: Could not instantiate mail function.

    Hi, in order to send an email through SMTP you need to setup the connection correctly, right now you are pointing the **host** to `localhost` instead of something like `smtp.domain.tld` …
  • Member Avatar for cereal
    cereal

    Began Watching Mailer Error: Could not instantiate mail function.

    Hi everyone, tried to send email from localhost using smtp mail function but unable to do so. The error is "Could not instantiate mail function. Mailer Error: Could not instantiate …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Changing the css codes just by pressing a button

    > I am trying to change the whole 3 circles with one button press. Any clue how? Why only one circle that changes color? The reason is the [ID (unique …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Changing the css codes just by pressing a button

    > I don't think the margin has an issue. That's correct, in fact, I was referring to CSS properties with a specific feature: hyphens.
  • Member Avatar for cereal
    cereal

    Replied To a Post in Changing the css codes just by pressing a button

    In Javascript, hyphenated CSS properties `margin-top` & co. are converted to lower camel case, so `marginTop`. Line 27 has this issue. See: https://developer.mozilla.org/en-US/docs/Learn/JavaScript/Client-side_web_APIs/Manipulating_documents
  • Member Avatar for cereal
    cereal

    Replied To a Post in Highest Common Factor in Haskell

    Hi! Those are definitions of the same function (hcf), the first line is defining a default in case the second argument is 0, in that case returns the first argument …
  • Member Avatar for cereal
    cereal

    Began Watching Highest Common Factor in Haskell

    Hi, I'm really, *really* new to Haskell. I'm practicing with simple online questions and there's a hcf question which I found the answer to online(http://snipplr.com/view.php?codeview&id=11973) but I still don't understand …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Changing the css codes just by pressing a button

    You have already asked this: * https://www.daniweb.com/programming/web-development/threads/500001/changing-style-color * https://www.daniweb.com/programming/web-development/threads/461404/change-css You received solutions in both threads. Bye.
  • Member Avatar for cereal
    cereal

    Began Watching Changing the css codes just by pressing a button

    Hello, Any idea how to change the css codes just by pressing a button? I wonder how to do this? Any clue?
  • Member Avatar for cereal
    cereal

    Replied To a Post in How To Display In iFrame A Url From Mysql ?

    You have to print the $row: <iframe src="<?php echo $row["blog"]; ?>"></iframe> See if this helps.
  • Member Avatar for cereal
    cereal

    Began Watching How To Display In iFrame A Url From Mysql ?

    Hi, Imagine there is a tbl called "users" and it has a column called "your blog url". Now, imagine you want to display that blog's url in an iframe on …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Php function error

    Hi, in this case the artisan command won't solve the issue, because it's PHP telling those functions are deprecated as PHP 7.1.0. The Mcrypt library has been declared deprecated and …
  • Member Avatar for cereal
    cereal

    Began Watching Php function error

    Hi, i tried to install php project in localhost using xampp and encounter the error below. Please advise how to solve the issue. Thanks. A PHP Error was encountered Severity: …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Hackers - the worst case scenario

    Very wide. Depends on the role and the permissions connected to these credentials. What can be done with them: can you connect, for example, to the internal network through a …
  • Member Avatar for cereal
    cereal

    Began Watching Hackers - the worst case scenario

    What’s the worst that could happen if someone’s account credentials within your organisation fell into a hacker’s hands?
  • Member Avatar for cereal
    cereal

    Replied To a Post in strpos Counts From Which Pos ?

    Agree, preg results are painful. The following should ship the same output with preg_match_all(): $results = array_column($matches[0], 1); However, I suspect it will add some overhead.
  • Member Avatar for cereal
    cereal

    Replied To a Post in strpos Counts From Which Pos ?

    You can also use a regular expression (regex), in PHP you can use regex with `preg_*` functions: preg_match_all('/5/', $numberedString, $matches, PREG_OFFSET_CAPTURE); The first argument is the pattern to search, the …
  • Member Avatar for cereal
    cereal

    Began Watching strpos Counts From Which Pos ?

    Hiya, http://www.tizag.com/phpT/php-string-strpos.php On the above link, it is stated: PHP Code: $numberedString = "1234567890"; // 10 numbers from 1 to 0 $fivePos = strpos($numberedString, "5"); echo "The position of 5 …
  • Member Avatar for cereal
    cereal

    Gave Reputation to AssertNull in strpos failing to output FALSE!

    I'm confused why PHP chose to return FALSE rather than -1 (not found) like C++ (string::npos) here. It's returning an index. Why bother mixing types? What's the advantage? A negative …
  • Member Avatar for cereal
    cereal

    Replied To a Post in strpos failing to output FALSE!

    In addition: it happens because it's boolean FALSE which is converted automatically to an empty string, you won't get a string FALSE, for example: echo "FALSE"; # string, printed echo …
  • Member Avatar for cereal
    cereal

    Began Watching strpos failing to output FALSE!

    It is said on the following link: **Using the strpos() function** **The strpos() function is used to search for a string or character within a string.** **If a match is …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Boolean's Double Troubles

    > Saying all this, I guess white space or the TAB/INDENT is considered as FALSE if some-how there can be "values" set to them one way or the other. Have …
  • Member Avatar for cereal
    cereal

    Began Watching Boolean's Double Troubles

    Q. On this page: https://www.tutorialspoint.com/php/php_variable_types.htm On section "Interpreting other types as Booleans", it says: **"Don't use double as Booleans".** I do not understand this. Why can't you use a double …
  • Member Avatar for cereal
    cereal

    Began Watching Array - columns

    Hi, 1. I would like to ask how can I adjust array.csv like this: ,,,-00.000146400000, 0.08000, ,,,-00.000146200000, 0.00000, ,,,-00.000146000000, 0.00000, ,,,-00.000145800000, 0.00000, so I can have in first column -00.000146400000 …
  • Member Avatar for cereal
    cereal

    Gave Reputation to KagaKuro in Codeigniter , PHP (submit contact form to email)

    its okay. things just got complicated. dumb me haha
  • Member Avatar for cereal
    cereal

    Replied To a Post in Codeigniter , PHP (submit contact form to email)

    > can you help me set up the controller and stuff ? or you cant... Hi, what do you mean?
  • Member Avatar for cereal
    cereal

    Gave Reputation to happygeek in class

    ???
  • Member Avatar for cereal
    cereal

    Replied To a Post in How to bind a parameter once as INT once as STR

    Almost, in the query you should write AND/OR between the WHERE clauses, and `execute()` does not allow two parameters, so you should merge the array, and in this case convert …
  • Member Avatar for cereal
    cereal

    Gave Reputation to Reverend Jim in Visual Regular Expressions

    For anyone who is having trouble with regular expressions, I suggest you have a look at [this site](https://regexper.com/#%5Cd%7B1%2C3%7D) by Jeff Avallone. It takes a regular expression in the native (cryptic) …
  • Member Avatar for cereal
    cereal

    Began Watching Python [Errno -9996] Invalid output device (no default output device)

    I'm currently working on multithreading with PyAudio and Pygame, but when I try to run the audio, I get an error saying "OSError: [Errno -9996] Invalid output device (no default …
  • Member Avatar for cereal
    cereal

    Replied To a Post in How To Check Whether An Html Element Or Plain Text Exists On A Page Or Not

    In the specific case of Twitter, there is an API that allows to search through the public tweets of a specific account: * https://dev.twitter.com/rest/public/search You can check the libraries used …
  • Member Avatar for cereal
    cereal

    Began Watching How To Check Whether An Html Element Or Plain Text Exists On A Page Or Not

    Pros, Imagine you want to only provide your download link to those who tweet about you. Now, how would you code it ? Let's make it simple for you to …
  • Member Avatar for cereal
    cereal

    Gave Reputation to diafol in How to bind a parameter once as INT once as STR

    Ah the old sprintf ploy, eh? +1 sorry can.t give comment as on mobile. Wish Dani would sort that out!
  • Member Avatar for cereal
    cereal

    Replied To a Post in How to bind a parameter once as INT once as STR

    In addition: consider that a bind can be defined in the execute() method, so: $stmt->execute([':id' => $id]); You could change the queries to whitelist some expressions and add it as …
  • Member Avatar for cereal
    cereal

    Replied To a Post in How to bind a parameter once as INT once as STR

    Hi, `IS NOT NULL` is not a string, [it's an expression](https://dev.mysql.com/doc/refman/5.7/en/expressions.html). So, as far as I know, you cannot bind it into a prepared statement. Do two queries: if($gjendja_id > …
  • Member Avatar for cereal
    cereal

    Began Watching How to bind a parameter once as INT once as STR

    Hello, Recently I am starting to code my scripts in PDO method to manage the information in a mysql database. In this case I am having an issue how to …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Codeigniter , PHP (submit contact form to email)

    Hehe, sure you can! If you want to solve it, instead, read the notice, it says *Use of undefined constant session - assumed 'session'*, which means you probably wrote: $autoload['libraries'] …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Sorry for my absense

    Take care Dani!
  • Member Avatar for cereal
    cereal

    Began Watching Sorry for my absense

    Sorry for my absense. I've been sick since late March. What started as a bad cold turned into bronchitis, and is on its way to walking pneumonia. :( I'm on …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Codeigniter , PHP (submit contact form to email)

    Open *application/config/autoload.php* and set **session** inside: $autoload['libraries'] = array('session'); You can do the same with other libraries or helpers that you will use constantly, like database or form. More info: …
  • Member Avatar for cereal
    cereal

    Replied To a Post in Form input preview with printing

    Hi, it is not clear where you are having difficutiles.
  • Member Avatar for cereal
    cereal

    Began Watching Form input preview with printing

    I created an Php/Html form which will save to Database, the form is for Job application form, so i want it to preview the form details before final submission and …
  • Member Avatar for cereal
    cereal

    Replied To a Post in What is your current favorite hobby (besides technology) ?

    Mostly running, for few hours, 4 times per week, it's my break from everything. About plants, I don't have a garden anymore, but I have a small room with a …
  • Member Avatar for cereal
    cereal

    Began Watching What is your current favorite hobby (besides technology) ?

    Some years ago I was in fishing , then Mountain biking and almost one year now I am in gardening ( I still go for fishing or a biking ride in …
  • Member Avatar for cereal
    cereal

    Replied To a Post in What To Download Today From Youtube ?

    > Have you guys ever thought of building it ? It would sell well. Hmm, that would infringe YouTube [terms of services (ToS)](https://www.youtube.com/t/terms) I suggest you to not try to …

The End.