Go Back   CodingForums.com > Search Forums

Before you post, read our: Rules & Posting Guidelines

Showing results 1 to 25 of 50
Search took 0.09 seconds.
Search: Posts Made By: bjarneo
Forum: PHP 11-08-2012, 06:07 PM
Replies: 10
Views: 597
Posted By bjarneo
<td><input type='text' name'username'></td> ...

<td><input type='text' name'username'></td>

Try name='username'
Forum: PHP 10-30-2012, 12:17 PM
Replies: 5
Views: 451
Posted By bjarneo
Well, can you the code from 'myfile.php' ?

Well, can you the code from 'myfile.php' ?
Forum: PHP 10-29-2012, 08:01 PM
Replies: 5
Views: 451
Posted By bjarneo
Yes, but in your csv script, just use str_replace...

Yes, but in your csv script, just use str_replace before you print your output.

And yes, you can download the csv file created on your server.
Forum: PHP 10-29-2012, 02:46 PM
Replies: 5
Views: 451
Posted By bjarneo
How about just use str_replace? $str =...

How about just use str_replace?

$str = 'Categorias,26/10/2012 18:00,26/10/2012 19:00,26/10/2012 20:00,26/10/2012 21:00,26/10/2012 22:00,26/10/2012 23:00,27/10/2012 00:00,27/10/2012...
Forum: PHP 10-22-2012, 04:28 PM
Replies: 15
Views: 794
Posted By bjarneo
Why do you not just use MySQL driver for pdo?

Why do you not just use MySQL driver for pdo?
Forum: PHP 10-22-2012, 09:49 AM
Replies: 1
Views: 295
Posted By bjarneo
Try this-ish $strDate = "6/25/2012"; ...

Try this-ish


$strDate = "6/25/2012";

$t = strtotime($strDate);
$getDate = getdate($t);

printf('day is %d <br /> month is %d <br /> year is %d', $getDate['mday'], $getDate['mon'],...
Forum: PHP 10-21-2012, 07:20 PM
Replies: 1
Views: 333
Posted By bjarneo
"When use cookie based authentication with...

"When use cookie based authentication with phpymyadmin, mcrypt is missing on CentOS 6.2 by default.
Problem can be solved by installing EPEL repository.
For CentOS 6.2 x86_64, below is the steps to...
Forum: PHP 10-21-2012, 07:13 PM
Replies: 1
Views: 220
Posted By bjarneo
Just set a class (css) on lets say the span...

Just set a class (css) on lets say the span holding your value.

Quick example:


$valueDatabase = 80;
// Code above this is where you get the value(s) from your database

if($valueDatabase >...
Forum: PHP 10-21-2012, 07:04 PM
Replies: 3
Views: 459
Posted By bjarneo
And if you're not up to create this class...

And if you're not up to create this class yourself. TimThumb is an great option for resizing. TimThumb: http://www.binarymoon.co.uk/projects/timthumb/
Forum: PHP 10-21-2012, 11:13 AM
Replies: 1
Views: 388
Posted By bjarneo
Here's another solution: # Create a new...

Here's another solution:

# Create a new DirectoryIterator object with the path you want to iterate through
$dir = new DirectoryIterator('/wamp/www/cf');

# Clean array
$cleanArr = array();
...
Forum: PHP 10-20-2012, 10:01 PM
Replies: 1
Views: 373
Posted By bjarneo
Actually you don't need to use regex if you only...

Actually you don't need to use regex if you only want to match those urls.
Try strstr()

Example:

$url = "www.blahblahblah.com/show/index.php?product=item1";

$pattern =...
Forum: PHP 10-20-2012, 09:16 PM
Replies: 2
Views: 328
Posted By bjarneo
Just a question: Why do you not just use the API...

Just a question: Why do you not just use the API instead?
http://www.myfxbook.com/api

Since my code uses more than 2 seconds to get your result.
Forum: PHP 10-20-2012, 08:51 PM
Replies: 2
Views: 304
Posted By bjarneo
I actually don't understand what you need? ...

I actually don't understand what you need?

Anyways if you use shift+enter you get \n or \r\n. Can't remember right now.

So if you want to replace let's say \n with <br /> you do it like this:
...
Forum: PHP 10-20-2012, 08:43 PM
Replies: 2
Views: 328
Posted By bjarneo
I got an better approach: #1 Use DOMdocument...

I got an better approach:

#1 Use DOMdocument to load the html
#2 Use XPath query to get spesific html tag.

Note: this is just an example code I used 5min to create. So you need to tweak it.
...
Forum: PHP 10-20-2012, 06:08 PM
Replies: 9
Views: 446
Posted By bjarneo
Hehe, sleep makes debugging alot more easier :)

Hehe, sleep makes debugging alot more easier :)
Forum: PHP 10-20-2012, 05:43 PM
Replies: 9
Views: 446
Posted By bjarneo
Well it works as it should here. Are you sure...

Well it works as it should here.
Are you sure you are using the strip_tags ? and not striptags (except if this is a function you've created).


<?php

// sometimes this textarea is not blank...
Forum: PHP 10-20-2012, 05:33 PM
Replies: 9
Views: 446
Posted By bjarneo
Hmm, I'll test with a textarea. Actually...

Hmm, I'll test with a textarea.

Actually the owner of that site look at code all day :p What screen resolution do you use?
Forum: PHP 10-20-2012, 05:08 PM
Replies: 4
Views: 491
Posted By bjarneo
I think you should read more about basic php and...

I think you should read more about basic php and cookies. Then if you still don't know how to do it, ask.
Forum: PHP 10-20-2012, 04:55 PM
Replies: 9
Views: 446
Posted By bjarneo
$test['text'] = 'abcdefgh i aj sd ajkl dasnsad...

$test['text'] = 'abcdefgh i aj sd ajkl dasnsad asl a';

$rcur_comment = strip_tags($test['text']);

if (strlen($rcur_comment) < 5)
{
$rcur_comment = trim($rcur_comment);
}

if...
Forum: PHP 10-20-2012, 03:57 PM
Replies: 5
Views: 496
Posted By bjarneo
Check out PHP PDO:...

Check out PHP PDO: http://workbench.no/blog/php-pdo/

And you don't need to write separate query for each drop down item.

Read about queries.
Forum: PHP 10-20-2012, 03:52 PM
Replies: 9
Views: 446
Posted By bjarneo
Got any example code?

Got any example code?
Forum: JavaScript frameworks 05-29-2012, 02:50 PM
Replies: 4
Views: 390
Posted By bjarneo
Again thanks alot. Worked with this code: ...

Again thanks alot.
Worked with this code:

var HeaderMenu =
{
init: function()
{
var vis = true;
$("#nyhetsportal_menu_ul li").bind("click", function()
{
Forum: JavaScript frameworks 05-29-2012, 02:18 PM
Replies: 4
Views: 390
Posted By bjarneo
Thanks! I'll test your code, and try to make this...

Thanks! I'll test your code, and try to make this work. If I fail, I'll past my markup,
Forum: JavaScript frameworks 05-29-2012, 01:53 PM
Replies: 4
Views: 390
Posted By bjarneo
Show / hide by click

Hi,
If I want a button (the same button) to Show content and hide content on click, how do I do that?
I have now assigned two buttons, one for show and one for hide, but I want to use the same...
Forum: PHP 05-24-2012, 08:47 AM
Replies: 4
Views: 279
Posted By bjarneo
Yeah, that was pretty easy. I now realize...

Yeah, that was pretty easy.


I now realize I must read the php.net function manual better!

Thanks
Showing results 1 to 25 of 50

 
Forum Jump

All times are GMT +1. The time now is 01:53 AM.