cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Then is it possible to convert that C to C++ because that is just the standard code I was given on line 4?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I just tried removing the star at the top of the function and removing line 38 but I get the following error.

1>------ Build started: Project: gm_php, Configuration: Debug Win32 ------
1>Compiling...
1>main.cpp
1>c:\documents and settings\owner\my documents\visual studio 2008\projects\gm_php\gm_php\main.cpp(23) : warning C4190: 'explode' has C-linkage specified, but returns UDT 'std::basic_string<_Elem,_Traits,_Ax>' which is incompatible with C
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>,
1> _Ax=std::allocator<char>
1> ]
1>c:\documents and settings\owner\my documents\visual studio 2008\projects\gm_php\gm_php\main.cpp(56) : error C2664: 'std::basic_string<_Elem,_Traits,_Ax>::basic_string(std::basic_string<_Elem,_Traits,_Ax>::_Has_debug_it)' : cannot convert parameter 1 from 'std::string *' to 'std::basic_string<_Elem,_Traits,_Ax>::_Has_debug_it'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>,
1> _Ax=std::allocator<char>
1> ]
1> Constructor for struct 'std::basic_string<_Elem,_Traits,_Ax>::_Has_debug_it' is declared 'explicit'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>,
1> _Ax=std::allocator<char>
1> ]
1>Build log was saved at "file://c:\Documents and Settings\Owner\My Documents\Visual Studio 2008\Projects\gm_php\gm_php\Debug\BuildLog.htm"
1>gm_php - 1 error(s), 1 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

Also I tried removing the star at the beginning and the star at "result" variable then removed line 38 and got the following error.

1>------ Build started: Project: gm_php, Configuration: Debug Win32 ------
1>Compiling...
1>main.cpp
1>c:\documents and settings\owner\my documents\visual studio 2008\projects\gm_php\gm_php\main.cpp(23) : warning C4190: 'explode' has C-linkage specified, but returns UDT 'std::basic_string<_Elem,_Traits,_Ax>' which is incompatible with C
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>,
1> _Ax=std::allocator<char>
1> …

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

i am trying to create a login page so the staff will be directed to one place while the students will be directed to another. this code is still in the making hence no location function was included as yet. can any one help me with this code please

Hey, your username is similar to mine. Was that deliberate lol. Anyways is this a code snippet for the gallery or is it a problem you want others to help solve. If it is a problem you want others to help solve then I would suggest telling the moderators that this is not a code snippet but instead a forum thread. That can be done with the flag bad post button.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Hi and I am making a dll but the dll won't accept pointers due to what it links to. So below is my code and does anybody know how to make a string array without pointers? Also I'm using Visual c++ 2008.

//#pragma warning(disable:4996) //disable "depreciated function" warnings
#include <windows.h> //required for dll
#include <sstream>
#define DLLEXPORT extern "C" __declspec ( dllexport )


BOOL APIENTRY DllMain( HMODULE hModule,
                       DWORD  ul_reason_for_call,
                       LPVOID lpReserved
					 )
{
	switch (ul_reason_for_call)
	{
	case DLL_PROCESS_ATTACH:
	case DLL_THREAD_ATTACH:
	case DLL_THREAD_DETACH:
	case DLL_PROCESS_DETACH:
		break;
	}
	return TRUE;
}

 DLLEXPORT std::string *explode (std::string exploder, std::string original, int limit=0) {
	std::string tmp;
	tmp=original;
	int num, loc, x, limiter;
	limiter=0;
	num=1;
	while (tmp.find(exploder)!=std::string::npos) {
		if (limiter==limit && limit!=0) { break; }
		if (limit>0) { limiter++; }
		loc=tmp.find(exploder);
		tmp=tmp.substr(loc+exploder.length());
		num++;
		}
	std::string *result;
	x=(num+1);
	result = new std::string[x];
	/*std::string s;
	std::stringstream out;
	out << x;
	s = out.str();
	result[0]=s;*/
	result[0]="1";
	num=1;
	tmp=original;
	while (tmp.find(exploder)!=std::string::npos) {
		if (limiter==limit && limit!=0) { break; }
		if (limit>0) { limiter++; }
		loc=tmp.find(exploder);
		result[num]=tmp.substr(0,loc);
		tmp=tmp.substr(loc+exploder.length());
		num++;
		}
	result[num]=tmp;
	return result;
}

Thanks...

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Are there any rainbow tables api's available for sha1, crc32 and crc32b.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Well what I wanted to do was use java the same way you would use ajax. But I am having problems connecting/streaming to external webpages using a Java applet. Anybody know the solution?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Here is the basic code.

<?php
if (!empty($_GET['a']) && !empty($_GET['b']) && !empty($_GET['c'])) {
    $result=(int) $_GET['a']+ (int) $_GET['b'] - (int) $_GET['c'];
    echo 'Answer: '.$result;
}
?>
<form method="GET">
Total: <input type="text" name="a"><br>
Add: <input type="text" name="b"><br>
Minus: <input type="text" name="c"><br>
<input type="submit" value="Calculate">
</form>

Also you may want to read up on a few php tutorials. The link in my signature contains some useful tutorials.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Just tried your code and still nothing... My code makes a Java Applet and not an Application so does that make a difference as to how your code should be done. Also I tried sending the error messages to a text box and they didn't display neither. Please help...

There are no errors displayed because you are catching the exceptions and not doing anything with them. Try this to see what is happening:

} catch (MalformedURLException me) {
  System.err.println(me.getMessage());
} catch (IOException ioe) {
  System.err.println(ioe.getMessage());
}
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Hi and I have made a simple Java function/method and for some reason it is not working. It doesn't show errors. It doesn't display results. It returns nothing and forces other things around it to do nothing. Below is my script.

private String get_url(String address) {
    String result="";
        try {
            URL yahoo = new URL(address);
            URLConnection yahooConnection = yahoo.openConnection();
            //DataInputStream dis = new DataInputStream(yahooConnection.getInputStream());
            BufferedReader dis = new BufferedReader(new InputStreamReader(yahooConnection.getInputStream()));
            String inputLine;
            while ((inputLine = dis.readLine()) != null) {
                result=result+inputLine+"\n";
            }
            dis.close();
        } catch (MalformedURLException me) {
        } catch (IOException ioe) {
        }
    return result;
    }

And to call it I used the following:

jTextArea1.setText("-"+get_url("http://google.com.au/"));

But yet it doesn't even show that dash. And as soon as I remove the get_url() function the dash will display. It should display the html code of Googles homepage. Can anybody see what is wrong with my code as there are no errors reported and the function just won't display the html code...

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Chances are cookies are not enabled in IE8. So go into your options and enable cookies then sessions should work.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Cool. Dani and I both like the same show. Wouldn't have guessed that but what your favorite episode because I am beginning to watch all 7 seasons from start to finish and am about half way through the first season. I like the part where there is a war between the enemy vs Macgyver. Then Macgyver sets all of these traps and is so great to watch. When I come across a problem the first thing I think of is "what would Macgyver do?" and answering that question usually solves it.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I do and does anybody here really like the series or am I the only one.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

If there aren't any questions relating to the subject, it would be useless to add a forum. But if there are a lot of questions on the subject in an appropriate/related forum, then it makes sense.

The thing is there is a media sub-forum but is hidden deep below the categories. Perhaps if this forum was moved to Web Development or Software Development instead of a subforum of Web Design then more people will see that it is there. I find it kinda annoying how it's hidden in it's own corner so I tend to not visit it.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Also while this topic is active could somebody mention why there isn't a forum for 3d modelling and digital artworks other then the web development multimedia. Would it be possible to create such a forum or perhaps move the multimedia forum to somewhere where it is more accessible by the menus.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Happy New Year everyone! Its year of the tiger, right?

The year of the tiger was two years ago wasn't it? The year when apple computers released their operating system called "Tiger". If however you are talking about Tiger Woods then his long gone after what he has done.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Try the following as you had a few bugs...

<?php
include ('mysql.php');

if(isset($_POST['submit'])){
      $username = mysql_real_escape_string($_POST['username']);
      $password = mysql_real_escape_string($_POST['password']);	  
      $sql = mysql_query("INSERT INTO users (user_id, username, user_password, user_regdate) VALUES('hi','$username','$password','beta')");
?>			 
<form action="register.php" method="post">
<input type="text" name="username">
<input type="password" name="password">
<input type="submit" name="submit" value="Register">
</form>

Hi,

Iv'e been reading through all the different posts and searching the web all day and I am not sure what went wrong I am getting this error

"Parse error: syntax error, unexpected T_STRING in /home/gamersh1/public_html/database/register.php on line 9"

Code: Register.php

<?php
include ('mysql.php');

if(isset($_POST['submit'])){
          $username = ($_POST['username']);
          $password = ($_POST['password']);
		  
		     $sql = mysql_query("INSERT INTO users (user_id, username, user_password, user_regdate)
								   VALUES("hi","$username","$password","beta")
								   ?>			 
<form action="register.php" method="post">
<input type="text" name="username">
<input type="password" name="password">
<input type="submit" name="submit" value="Register">
</form>

And the i also have my mysql connect page: mysql.php

<?php


$host = 'localhost';  // mysql server domain
$user = 'root';      // mysql username
$pass = 'root';     // mysql password
$db = 'dinopanel';  // mysql database name

'$connect' = '@mysql_connect($host,$user,$pass) or die ('Error connecting to database'))'

$select = @mysql_sellect_db($db,$connect) or die ('Error selecting database');

?>

Can any of you see any errors in this I am new to php and mysql

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Wonder how large "they could have infinite numbers" is?

Well the size of the number is only limited to your cpu with the bcmath library. So for example the average cpu could multiply two numbers totaling to 1,000,000,000 digits. That is a lot better than 32/64 bit numbers. I am also working on my own c++ math library for infinite sized numbers such as pi.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Is this thread about the Unix timestamp 2038 bug when 32-bit integers run out of numbers. If they used the php bcmath library for the timestamp then they could have infinite numbers. Imagine the possibilities if they made a type of integer which could hold infinite numbers. That would be cool and might be what they will have to do by the end of the millennium.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Now I changed my mind and the site will only allow admins to login so now I need to modify the login just to suit admin needs but my problem is since it won't be wise to build a register script for admins
how do I add new admins!
I mean do I add admins account myself and just put the login there or something like that.
Can someone help me please?

Sounds like it's mainly the theory that has gone terribly wrong. I shall explain the answer and if you have any problems then I shall provide some code. So as explained you have a register script and a login script. That is all and good and now for the next stage. You will need to put into your config file a username variable and a password variable for the master username and master password. Then modify the login script to accept this master user. Then when the master user is logged in a cookie or session variable is set to say it is the master user. And add an if statement in the register script to check if it is the master user registering a new user. Then last of all make sure the register page is only linked to in the master admin panel and not in everybody else's admin panel and not in public domain. That's the theory and hope it gives you a better picture.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

If you don't mind me asking, what is your profession?

Well currently I'm not employed but I do enjoy making websites and helping others who don't know much about computers. My knowledge extends across a wide variety of languages including php, php-gtk, java, javascript/html/css, c++ and gml. I like to think of languages as like fruit and vegetables where they may not taste good but they do a great job. Hope you enjoyed that bio.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Do you have to analyze so much? I read through your thread on pi... and now on this thread, you want to believe that it is not a new decade based on what scientists are saying... just an observation from a not so frequent poster.

Well if your on a computer forum then surly you know numbers start at 1 and in fact on the keyboard it goes 1234567890 with 0 at the end. That means we would be in the last year of that decade. Also for all those computer geeks like me you may have heard on the news the timestamp 1234567890 marked the digital birth of christ in 2009. Notice the digital birth of christ wasn't 0123456789. And you may notice that when counting backwards from 2 you don't get a negative zero. There is only 1 zero at the beginning including negatives. That is because the zero at the beginning is a negative.

The reason I am pointing all of this out is because otherwise we would be in the 20th century since it's year 2000 and not 21st century if what you say is correct. However if numbers start at 1 then that forces the century number to be ahead by 1 and some with when the decade starts etc.

Don't be offended by this but it is just a general debate going around town to town.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I'm interested too. Where are all of these great video cms's as I need one too which doesn't require and specialized server software.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Well it's also a New Decade! Let's hope you all have a good one!

Scientists say the new decade starts in 2011 just like how the number century is one number ahead. Also I believe we still have another two months until new year as scientists are debating weather we should have a leap minute every 5 or so years. So with all of these factors the new decade starts in another 14 months and the new year starts in another 2 months.
That is what I believe but don't criticize me if you believe different.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Let me repeat myself - the calendar is an arbitrary numbering of the years so what you are saying is that the arbitrary Chinese new year is more accurate than the arbitrary AD yadda yadda yadda.

Exactly while still using the 2009 instead of four thousand and something.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

It appears the Chinese new year is more accurate than the AD new year while using the AD numbering system. Amazing how smart the Chinese are.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Do you have the database software installed on the machine the script is being run on? This can be a problem with php-gtk as when you transfer the program to another computer then the database will need transferring too so that both the database and the script are on the same computer. To be more detailed if for example you were trying to read a mssql database or even mysql database you will need to go to the mssql or mysql website, download their software and install it onto your computer then use something like phpmyadmin to add the database to the software. Then the php extension library will communicate with that sql software to retrieve data.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Earth orbits the Sun at an average distance of about 150 million kilometers every 365.2564 mean solar days. Mean days they are at times!

If it is true that there is 365.2564 days in a year then that means we in about November 2009. Does anybody believe this?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I was being facetious more than anything about the 0.25, I know it's important. However, with your calculations you were losing 5 days per year.

Thanks for pointing that out. I adjusted the formula to the following and it yields 2010.

<?php
$time=mktime(0,0,0,1,1,2020)-mktime(0,0,0,1,1,1980);
$ratio=2010/40;
$time=$ratio*$time;
$year=floor($time/(365.25*24*60*60));
echo $year;
?>

At last proof that the current year is 2010. Also who here no longer uses the traditional AD system. I myself prefer not to use the AD system and instead use the unix timestamp system for everything including remembering events and dates.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

(+0.25 fudge factor)

Well you need to add that factor otherwise we would will loose 1 day every 4 years. So 1 leap day divided by 4 years = 0.25 days. Then you add that to the total days in the year and you will get a more accurate figure leap year inclusive...

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

$year=floor($time/([B][I][U]360.25[/U][/I][/B]*24*60*60)); If you're going to be Captain Smartguy, you ought to have your numbers correct at the very least.

The reason why I had 360.25 is because every 4 years don't we get an extra day? So that would mean the average year would have 360.25 days or in your opinion how many days are there in the average year factoring in leap years?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Looks like that mktime function is set to the local timezone. I think I have made the appropriate fixes and we are not that far in the past where the year is 2037.

<?php
$time=mktime(0,0,0,1,1,2020)-mktime(0,0,0,1,1,1980);
$ratio=2010/40;
$time=$ratio*$time;
$year=floor($time/(360.25*24*60*60));
echo $year;
?>

With this script the subtraction should compensate for the timezone difference and I have fixed a bug on line 3.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Have you ever thought of the current year to be 400,002,509 because when you think about it there has been organisms on our planet for over 400 million years so wouldn't you logically count from when time started?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Hi and I am having trouble with one of the very most basics of java applets. That is putting the applet into a webpage and in that webpage specifying some parameters. The below is my code:

<object classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93" ARCHIVE="chatroom$1.class, chatroom$2.class, chatroom$3.class, chatroom.class, extender$innerclass.class, extender.class" width="500" height="480">
<PARAM name="archive" value="chatroom$1.class, chatroom$2.class, chatroom$3.class, chatroom.class, extender$innerclass.class, extender.class">
<PARAM name="code" value="chatroom.class">
<param name="id" value="doublecheck">
</object>

And as you can see I have about 6 files working together as the one applet. (Just how my compiler compiled it) Also I want to use the <object> tag instead of the <applet> tag so does anybody know how I can do this. The archive specifier was valid in the applet tag but appears not to be valid in the object tag. Not sure what to do about that?
And after that problem is sorted I will be able to test it for other problems as before it would only read "id" as a blank string so that is why i'm using <object> since <applet> is depreciated and <object> is more compatible (*cough* chrome *cough*).
Please help.
Thanks and happy new year.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

No. Its 2010, build a bridge, get over it.

Still 2009 for another 2 hours 15 minutes here but how did they determine the year in the first place. Surely at some point somebody forgot what the date and made a guess. How do we know for sure that everybody has been counting it correctly. What about leap years and all of that which scientists are complaining about saying we should have a leap minute...

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

In case anyone is after the missing link to human creatures then I'm the missing link.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I believe that is the correct syntax however the files should be accessible with AND without rewritten urls. Also if you want to make sure apache doesn't get into an infinit loop causing a 500 error then you could use the following:

RewriteEngine On 
RewriteCond %{HTTP_HOST} ^nu.wetwork\.org\.uk
RewriteRule ^(.*)$ http://www.nu.wetwork.org.uk/$1 [R=301,L]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^/?(.*)/(.*)/?$ /index.php?adran=$1&tud=$2

So to explain what those last three lines do, the two lines near the end beginning with RewriteCond% check that it is not rewriting a file or directory. Then the last line matches the regex on the left in the url and if that matches it views the page on the right similar to the preg_replace syntax. Is that what your after because you may need to just try viewing it in the new format and linking to the new format as both ways exist when using mod_rewrite?

diafol commented: Brilliant! thank you very much - I was going off my rocker! +5
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I have done some calculations and found that us humans have been counting leap years wrong in the past whatever years. It is not the year 2010 but instead 2509. The proof - check out the below php script which should display 2009 using timestamp ratios but instead displays a time in the future.

<?php
$time=mktime(0,0,0,1,1,2020);
$ratio=1980/40;
$time=$ratio*$time;
$year=floor($time/(360.25*24*60*60));
echo $year;
?>

So what are your opinions on this. I believe history is wrong and somebody has forgotten to add those leap years. Enjoy...;)

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

is spammer the who wonder I.

Now that's strangly worded. Reverse the words and you get the sentence.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

The countdown is on until time 1262257200 seconds from 1980 GMT+13. That's how I read time. Hope everybody enjoyed their christmass holidays and that last years resolutions came true.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Try modifying along the lines of this

RewriteEngine On 
RewriteCond %{HTTP_HOST} ^nu.wetwork\.org\.uk
RewriteRule ^(.*)$ http://www.nu.wetwork.org.uk/$1 [R=301,L]

RewriteRule ^/?(.*)/(.*)/?$ /index.php?adran=$1&tud=$2
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Try this:

<?php
// Fill up array with names and type
$a[]="Anna -silver"; // what i want when the name is                              
$a[]="Brittany-silver";//being typed it would not show the name 
$a[]="Cinderella-gold";// it would only show the type
$a[]="Diana-bronze";


//get the q parameter from URL
$q=$_GET["q"];

//lookup all hints from array if length of q>0
if (strlen($q) > 0)
  {
  $hint="";
  foreach($a AS $b)
    {
    if (strtolower($q)==strtolower(substr($b,0,strlen($q))))
      {
      $var=$b;
      $var=explode('-',$var);
      $var=$var[(count($var)-1)];
      if ($hint=="")
        {
        $hint=$var;
        }
      else
        {
        $hint=$hint." , ".$var;
        }
      }
    }
  }

// Set output to "no suggestion" if no hint were found
// or to the correct values
if ($hint == "")
  {
  $response="no suggestion";
  }
else
  {
  $response=$hint;
  }

//output the response
echo $response;
?>
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Is this the code your after

<?php
if (isset($_POST) && !empty($_POST)) {
    $words=explode(' ',$_POST['name']);
    $sql='SELECT * FROM `table` WHERE';
    foreach ($words AS $word) {
        $sql.=' `name`="'.mysql_real_escape_string($word).'" OR';
        }
    $sql=substr($sql,0,-3);
    $r=mysql_query($sql) or die($sql.'<hr>'.mysql_error());
    while ($row=mysql_fetch_array($r) {
        echo $row[0].'------'.$row[1].'<br>';
        }
    }
?>
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Incase anyone doesn't know this is pi to 1000 digits as I believe it:
3. 1415926535 8979323846 2643383279 5028841971 6939937510 5820974944 5923078164 0628620899 8628034825 3421170679 8214808651 3282306647 0938446095 5058223172 5359408128 4811174502 8410270193 8521105559 6446229489 5493038196 4428810975 6659334461 2847564823 3786783165 2712019091 4564856692 3460348610 4543266482 1339360726 0249141273 7245870066 0631558817 4881520920 9628292540 9171536436 7892590360 0113305305 4882046652 1384146951 9415116094 3305727036 5759591953 0921861173 8193261179 3105118548 0744623799 6274956735 1885752724 8912279381 8301194912 9833673362 4406566430 8602139494 6395224737 1907021798 6094370277 0539217176 2931767523 8467481846 7669405132 0005681271 4526356082 7785771342 7577896091 7363717872 1468440901 2249534301 4654958537 1050792279 6892589235 4201995611 2129021960 8640344181 5981362977 4771309960 5187072113 4999999837 2978049951 0597317328 1609631859 5024459455 3469083026 4252230825 3344685035 2619311881 7101000313 7838752886 5875332083 8142061717 7669147303 5982534904 2875546873 1159562863 8823537875 9375195778 1857780532 1712268066 1300192787 6611195909 2164201989. . .

I can't make it much clearer than that. Also I hear in pi there is a number combination 666666. Do you believe to same occurs for every other number?

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I have tried the Russian Peasant Algorithm and although it makes a great multiplication algorithm (which I needed) I still need however a division algorithm which is to some degree easy to understand. The basic requirements to this algorithm unlike before is that the algorithm can only contain addition, subtraction and multiplication (plus loops, greater than symbols and possibly a few other minor features) but one of the things it cannot contain is the >> or << operators. Can anyone provide such an algorithm and Newtons algorithm is terribly hard to translate as it uses devision to make the devision algorithm. Thanks...

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I would suggest following a tutorial and tizag is really good for learning.
http://www.tizag.com/ajaxTutorial/ajaxform.php

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Is this using wamp, xampp or a vps? Judging by the error message your not using wamp/lamp/xampp so if your running a localhost test server then I would suggest using wamp. If however that is not the case then the general solution in wamp is to reinstall the package or with xampp to downgrade to an earlier version. Wamp is better for new starters but if however you are using a vps then I would suggest reinstalling the php module as it may not have compiled correctly.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

I bit of css should do the trick.

<div style="border:1px #FFFFFF ridge; width:70px; height:70px; overflow-x: auto; overflow-y: auto;">
<select name='color[]' style="border:0px;" size=6 multiple>
<option value='' selected>Select Item</option>
<option value='blue'>Blue</option>
<option value='green'>Green</option>
<option value='red'>Red</option>
<option value='yellow'>Yellow</option>
<option value='white'>White</option>
</select>
</div>
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

It appears they have used two layers of encryption on they code making it incompatible with the version of php you are using. The two options are 1 - decode the data to something php can read or 2 - use a script php can read. As for decoding the data, I'm not sure how I myself could decode it but if you asked the makers of the script that might be able to give you a hand. BTW also check that the script is designed for php5 as that would make a big difference encoded or decoded. Sorry I can't be much of a help for this one as my attempts to decode it resulted in random symbols.

cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Do you mean something like this:

<select name="color[]" size=2 multiple>
<option value="" selected>Select Item</option>
<?php
$colors=array('Blue','Green','Red','Yellow','White');
foreach ($colors AS $color) {
echo '<option value="'.strtolower($color).'">'.substr($color,0,3).'</option>'."\n";
}
?></select>
cwarn23 387 Occupation: Genius Team Colleague Featured Poster

Well post the code of that file and we shall take a look at it for you Don't forget to use code tags...