Awah Mohamed -5 Junior Poster

hi guys, i am making a new app in cakephp (and i am new to the framework.. learned how to use it last night).. and i am supposed to make a signup system and login system but i am stuck in the signup.
i Worte the models and controllers and even the template for the signup but the system can't save the submitted data:
here are the codes..
=> Module: (user.php)

class User extends AppModel{
    var $name = "User";

=> UsersController.php

class UsersController extends AppController{
    var $name = "Users";
    function index(){
        $this->set("users", $this->User->find("all"));

    function signup(){

               $this->Session->setFlash("Signup Complete!!");
               $this->redirect(array("controller"=>"pages", "action"=>"index"));
                $this->Session->setFlash("An error has occured. Please Try again");
               $this->redirect(array("controller"=>"users", "action"=>"signup"));


    function login(){


and here is my signup.ctp

<?php include "../includes/header.php"; ?>
<section id="registration">
<small>Register Now and enjoy with all the ATLANCER.NET's features!</small>
echo $this->form->create("Users", array("action"=>"signup"));
echo $this->form->input("email");
echo $this->form->input("password");
echo $this->form->input("nationality");
echo $this->form->input("phone");
echo $this->form->end("Sign up!");

and this is my database table:

  `id` int(255) unsigned NOT NULL AUTO_INCREMENT,
  `name` varchar(255) NOT NULL,
  `email` varchar(255) NOT NULL,
  `address` varchar(255) NOT NULL,
  `credit` int(255) NOT NULL DEFAULT '5',
  `name_url` varchar(255) NOT NULL,
  `signup_date` datetime NOT NULL,
  `nationality` varchar(255) NOT NULL DEFAULT 'Rwandan',
  `birth_year` int(4) NOT NULL,
  `birth_month` int(2) NOT NULL,
  `birth_day` int(2) NOT NULL,
  `dream` text NOT NULL,
  `number_of_bids` int(255) NOT NULL,
  `number_of_work_done` int(255) NOT NULL,
  `rank` int(2) NOT NULL DEFAULT '1',
  `atrank` int(2) NOT NULL,
  `categories` int(11) NOT ...

alright cool.. but you should have tried more... you should always try harder to solve problems! :)

is very big. How can I change its size

you can simply adjust the size of the logo using html.. this is what i usually do..

you can use the width and height attributes in html. eg:

<img src="logo.jpg" width="250" height="200" />

and depending on the width and height of your logo.
in your case, i think it should look something like:

<<?php echo $tag; theme_logo(); ?>   <a href="<?php echo get_option('home'); ?>/"><img src="<?php bloginfo('template_url'); ?>/images/logo.jpg" alt="<?php bloginfo('description'); ?>" width="250" height="100" /></a></<?php echo $tag; ?>>

or do you mean the file size?(KBs/MBs)

and by the way, if my answers are solving your questions, please give me up votes. haha.. i need to increase my ranking in this site (i like being ranked high) :)

your code have a syntax error like it was reported.. :p

<<?php echo $tag; <?php theme_logo(); ?>   <a href="<?php echo get_option('home'); ?>/"><img src="<?php bloginfo('template_url'); ?>/images/logo.jpg" alt="<?php bloginfo('description'); ?>" /></a></<?php echo $tag; ?>>

in line 2, you have :

<?php echo $tag; <?php theme_logo(); ?>

it is supposed to be something like:

<?php echo $tag; theme_logo(); ?>

so your final code should be something like:

<<?php echo $tag; theme_logo(); ?>   <a href="<?php echo get_option('home'); ?>/"><img src="<?php bloginfo('template_url'); ?>/images/logo.jpg" alt="<?php bloginfo('description'); ?>" /></a></<?php echo $tag; ?>>

i think it is something like a wordpress theme or something right? anyways, the wrong thing is you have <?php and then <?php
try removing it and lets see if it will make a difference..

Yup u r right
Actually yesterday I was pissed..
Anyways, I think u r right... And about developing my emotional side, I definitely need to do that!!
I actually connected it with being a geek couz geeks don't play around too much.. Their emotional side is well developed...

Awah Mohamed -5 Junior Poster

Hi guys!
My name is Awah and i am a web developer! ("I love calling my self like this! ;) ");
Okay! Here is my problem! I am a 17 years old guy who is obsessed with programming and web development! I finished high school and going to collage soon... I own a web development company!

This is not the problem! the problem is, In the country where i am now (Rwanda), there are no proper geek friends who i can hang out with!!! And the bigger problem is not many developers go to Facebook!

I can't fit in with those who are not developers! they spend their time talking about shit and i honestly get bored the whole time when i am with any of them... specially they all tend to use their mother language which i don't speak!

And you know, whenever i get a friend who is into programming and stuff, they always tend to feel them selves too much! they always think that they know everything and they can do anything which is annoying couz i have knowledge in 19 programming languages and certified in 13 of them which also makes me have good programming skills! It is just annoying when someone who knows nothing feels him selfe too much!! And they all tend to never share anything related to programming or development with me even thought i share almost all of my softwares and codes with them!!!

Ok this is the summery, guys, tell me ...

I will see if I can do a simple str_replace function to get rid of those deviated characters... it should not be that hard.

No! I am not a genius yet.. my professor still labeled me as the mathematical wiz Kid from Fullerton.., but once I am able to solve the famous Riemann hypothesis without inflecting any damage to my brain, then I would probably consider myself as junior genius. But then again that is too much responsibilities I think.. I only dream of setting on a nice beach folding chair while holding a nice cold frappuccino in my right hand that's

hey! thanks! i just saw ur reply!
haha.. but still ur a genius to me! :)

i wrote a str_replace code to get these chars out

$code = $_POST['code'];
$code = base64_decode($code);
$code = str_replace("3", "u", $code);
$code = str_replace("4", "i", $code);
$code = str_replace("2", "o", $code);
$code = str_replace("1", "a", $code);
$code = str_replace("5", "e", $code);

echo  $code;

and the code gets submitted from a from using post method..

it works.. i am now looking for a way to make a stronger encoding system.. i want to make one that can never be decoded! :)

ok cool
now how does the code gets enterprated??
like if i wrote a function in an encoded form and also base64 encoded.. how can the code run??

@veedeoo: thanks a lot!! thats a very amazing explanation!! i am now viewing the str_replace page you wrote!
thanks a gain!!
but i gota admit! u r a genious in this!!

Awah Mohamed -5 Junior Poster

hi guys,
well, i was looking at some stuff in my laptop and found the following encoded code
it is from a wordpress template but its decoding mechanism is very interesting and i would like to know how it is made

so here is the full code:

 <?php $_F=__FILE__;$_X='Pz48P3BocA0KDQokcDFkZF9nMzRkID0gJyc7DQoNCmYzbmN0NDJuIHAxZGRfdGg1bTVfY3I1ZDR0cygpIHsNCglnbDJiMWwgJHAxZGRfZzM0ZDsNCgkkY3I1ZDR0cyA9ICdENXM0Z241ZCBieSA8MSB0MXJnNXQ9Il9ibDFuayIgdDR0bDU9IkI1c3QgU1VWIiBocjVmPSJodHRwOi8vczN2LnI1djQ1dzR0Mm5sNG41Lm41dC8iPkI1c3QgU1VWPC8xPiA0biBjMjJwNXIxdDQybiB3NHRoIDwxIHQxcmc1dD0iX2JsMW5rIiB0NHRsNT0iQTNkNCBTVVYiIGhyNWY9Imh0dHA6Ly9zM3YucjV2NDV3NHQybmw0bjUubjV0LzEzZDQtczN2LyI+QTNkNCBTVVY8LzE+LC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4kX0YuIiciLCRfWCk7ZXZhbCgkX1IpOyRfUj0wOyRfWD0wOw=='));?>

i worked on decoding it! so i separated the code into two by looking at the eval function

so here are the two parts of the code:


which is the value of $_X

and the second is the function that decodes it
which is:


now i decoded them both and here is $_X


$p1dd_g34d = '';

f3nct42n p1dd_th5m5_cr5d4ts() {
gl2b1l $p1dd_g34d;
$cr5d4ts = 'D5s4gn5d by <1 t1rg5t="_bl1nk" t4tl5="B5st SUV" hr5f="http://s3v.r5v45w4t2nl4n5.n5t/">B5st SUV</1> 4n c22p5r1t42n w4th <1 t1rg5t="_bl1nk" t4tl5="A3d4 SUV" hr5f="http://s3v.r5v45w4t2nl4n5.n5t/13d4-s3v/">A3d4 SUV</1>, <1 t1rg5t="_bl1nk" t4tl5="Inf4n4t4 SUV" hr5f="http://s3v.r5v45w4t2nl4n5.n5t/4nf4n4t4-s3v/">Inf4n4t4 SUV</1>, 1nd <1 t1rg5t="_bl1nk" t4tl5="L5x3s SUV" hr5f="http://s3v.r5v45w4t2nl4n5.n5t/l5x3s-s3v/">L5x3s SUV</1>';
$p1dd_g34d = 'c55oe00i-0579-udc9-8oe7-80cfb6io8bce';
$m5n3 = wp_n1v_m5n3(1rr1y(
'5ch2' => f1ls5,
'th5m5_l2c1t42n' => 'f22t5r',
'c2nt14n5r' => f1ls5,
'4t5ms_wr1p' => '%o$s',
'w1lk5r' => n5w P1dd_Th5m5_W1lk5r_Inl4n5_M5n3(),
$m5n3 = s3bstr($m5n3, 0, strl5n($m5n3) - strl5n('<sp1n cl1ss="p4p5"> | </sp1n>'));
5ch2 '<p cl1ss="m5n3">', $m5n3, '<br />';

5ch2 '<1 hr5f="http://www.p1dds2l3t42ns.c2m/" t4tl5="Fr55 W2rdPr5ss th5m5s" t1rg5t="_bl1nk">Fr55 W2rdPr5ss th5m5s</1> by P1dd S2l3t42ns.</p>';
5ch2 '<p cl1ss="1nn2t1t42n">', spr4ntf(__('C2pyr4ght &c2py; %6$s. %a$s. All r4ghts r5s5rv5d.', PADD_THEME_SLUG), d1t5('Y'), g5t_bl2g4nf2('n1m5')), ' <br />';
5ch2 $cr5d4ts, '</p>';
5ch2 '<d4v cl1ss="cl51r"></d4v>';

f3nct42n p1dd_th5m5_pr5l3d5_b5g4n() {
1dd_1ct42n('wp_h51d', 'p1dd_th5m5_pr5l3d5_b5g4n');

f3nct42n p1dd_th5m5_pr5l3d5_5nd() {
$c2nt5nts = 2b_g5t_c2nt5nts();
gl2b1l $p1dd_g34d;
4f (!5mpty($p1dd_g34d) && (f3nct42n_5x4sts('p1dd_th5m5_cr5d4ts'))) {
4f ($p1dd_g34d === 'c55oe00i-0579-udc9-8oe7-80cfb6io8bce') {
5ch2 $c2nt5nts;
} 5ls5 { ...

page. No need

it would work? let me try that..
thanks for the reply!

Awah Mohamed -5 Junior Poster

hi guys, well i am using .htaccess in my website to make SEO friendly urls..
the urls are supposed to look like this:

it is working nicely.. the problem is when i came to makin forms..
how should i submit my forms??
the .htaccess takes all the requests as a files and redirects all the calls to index.php
here is my .htaccess file that i made:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-l
RewriteRule ^(.*)$ index.php?url=$1 [L]

and here is my form:

<u><center><h1>Sign Up!</h1></center></u>

                    <form method="post" action="signup/process/">
                        <label for="Name">First Name:</label>
                        <input type="text" name="Name1" id="Name" />

                        <label for="Name">Last Name:</label>
                        <input type="text" name="Name2" id="Name2" />

                        <label for="City">Email:</label>
                        <input type="email1" name="Email" id="Email" />
                        <label for="City">Re-enter Email:</label>
                        <input type="email2" name="Email2" id="Email2" />
                        <label for="Email">New Password:</label>
                        <input type="password" name="Password" id="Password" />
                        <label for"I am">I am:</label> 
                        <select name="iam" id="select" style="height: 50px;">
                            <option id ="select">Male</option>
                            <option id="select">Female</option>
                        <label for="birthday">Birthday</lable>
                                <tr><td><select name="bday" id="select_small">
                                        <select name="bmonth" id="select_small">
                                    <td><select name="byear" id="select_small">
                                            <option id ="select">Year:</option>
                                            <option id="select">1990</option>


                            <input type="submit" name="submit" value="Submit" class="submit-button" />


so please tell me what is wrong with my code above??
whenever i submit something, the url looks as follows:

it torally doesn't make sense to me! please tell me wt to do...
thanks to anyone who tries to help me..

otocol but I am completely unfamiliar with it and can be of no he

thanks for your reply.. i am now checking the links and i hope that helps.. thanks again!

I am pretty sure though that you are looking for something different. So the interesting thing is: "what do you mean by a web socket?"

okay.. what i mean is:
lets assume i am making a user to user chat system using sockets... each of the users is having a connection to the same server but with different data being sent to the server.. the server is serving both users with the same port (lets say 5000).. now what will go wrong here?? and is this even possible?? i have tried it with ajax and jQuery but i am wondering if php socket servers can help making this... and i have looked on google about a user to user socket tutorial and i couldnt get anything useful...

my question have many different things inside it but lets start by how many users can connect to a socket server using the same port?

Awah Mohamed -5 Junior Poster

I was wondering how many connections in parallel can one web socket handle?
what i mean is if i made a chat socket and a million user connected to it at the same time, will it affect it in anyway? and if yes, what is the maximum number of connections can one socket handle? and is there anyway to make one web socket handle the maximum traffic possible??

i made a research on the internet but there seems like nothing that can help me.

hey! i got the solution.. i was supposed to make == instead of =
the final code is:

$url = $_GET['url'];
$length = strlen($url);
$url = explode('/', $url);
echo "<BR>";
if($length >= 0){
    echo "URL excits";
if($url[0] == 'home'){
    echo $url[0];

but for sure, the url will not be handling integers.. if i was to handle intergers i would have used == or === but these $url valies are completely letters or text

> ($_GET['url'])){
>     $url = explode('/', $_GET['url']);
>     print_r($url);
>     echo "<BR>";
>     echo "URL excits";
> }else{
>     $url[0] = 'home';
>     echo $url

$url is supposed to hold a string defined in the url.. like a page name.. e.g.: home, about, contact.. etc..

the code is supposed to include the page though home.php
it would be something like:

include $url.".php";

so by assuming that the url contains http://localhost/index.php?url=home
the code should see if the page is home and include it and at the same time have a complete list of things to do

if($url = "home")
set_headers("title", "home");
echo "welcome to the home page!!";
include $url.".php"; // for mre functions..
Awah Mohamed -5 Junior Poster

how can i use if statemend with strings in php?
and example is the following code:

$url = $_GET['url'];
$length = strlen($url);
$url = explode('/', $url);
echo "<BR>";
if($length >= 0){
    echo "URL excits";
if($url[0] = 'home'){
    echo $url[0];

but whenever i pass a parameter in the url, it displays home.. what is wrong?

i spent almost a year now without using php so i really nred your help. thanks for anyone who will try to help me.. :)

Awah Mohamed -5 Junior Poster

hi guys, how are you all?
well, i am participating in the google's science fair and my question is:
how can we make social networks student friendly?

and my aim is to make a social network that can be student friendly and also as professional as other social networks in the internet..
i'll be using php, sql, html5, css3, and (javascript / jquery).

so do you guys think that my topic is good enough to compete with the all those who are competing to get the scholarship or no?
and if you think there are specific things i have to do to make it impressive, please feel free to tell me...

and also please give me ideas that you think is good for a science fair and can me win the 1st position..
please guys!! thanks!

The function should do everything automatically.. Like it should automatically detect the new device and automatically send to it the file...

Awah Mohamed -5 Junior Poster

Hi guys, how are you?
Well, i have my science fair soon and i want to build a software that can copy any given file to any removable device that gets connected to the computer it is running on.. But the problem is i dont know how to do this... I am not that good in c++... So please help me..

In a simpler way, i am trying to write a c++ function that can copy lets say the file "exam.pdf" to any usb device that gets connected to the computer running the software containing that function.. How can i do it?? I looked on google and nothing useful came to me... Please people help me! And i will be greatful to anyone who will try to help!!

Awah Mohamed -5 Junior Poster

hi guys, how can i get the difference between two strings in PHP?
i mean lets say string 1 = "hello world"
and string 2 = "Hello World"
the php code should compare these two strings and output something like:
the difference between the two strings is 20%...

so how can i do this???

hey thanks!
that error is done.. now i have to solve the remaining ones!
thanks a lot!

Awah Mohamed -5 Junior Poster

hi guys, well.. i run my php program and the page just displays the following:
[CODE]Parse error: syntax error, unexpected ';' in C:\xampp\htdocs\Azone\Azone\profile.php on line 160[/CODE]

i checked line 160 more than 1,000,000 times and i got nothing to change!
here is the whole code of the page, please help me and tell me what to do!
code is bellow:
Note: i am not done from checking the code from errors.. i was editing one by one and this damn error stopped me!

$id = $_COOKIE['ln'];
$id = md5($id);
header("location: profile.php?uid=".$id);
if(isset($_GET['uid']) && isset($_COOKIE['ln']))
// the beginning of the full.php
include_once "engine/db/main.php";
$db = new db();
if(isset($_GET['uid'])){$uid = $_GET['uid']; $uid = mysql_real_escape_string($uid); } else { $uid = md5($_COOKIE['ln']); }
$uid = mysql_real_escape_string($uid);
$q = mysql_query("SELECT * FROM all WHERE md5id = '$uid'");
if(mysql_num_rows($q) == 0)
echo "window.location = '404.php'; ";
while($rows = mysql_fetch_array($q))
$name = $rows['name'];
$email = $rows['email'];
$location = $rows['country'];
$photo = $rows['profile_pic'];
$theme = $rows['theme'];
if(isset($_GET['uid'])) { $title = $name."'s Profile"; } else { $title = "Your Profile"; }
$des = $name."'s profile, profile, AZONE, ".$name;
$keys = $name.", profile, AZONE, ".$name."'s Profile";
include "engine/includes/temps/main/header.php";
include "engine/includes/temps/main/user_bar.php";
include "engine/includes/temps/main/separater.php";
include "engine/includes/temps/main/chat_bar.php";
include "engine/includes/left_bar.php";

Awah Mohamed -5 Junior Poster

Hi guys..
Well, i am an IB student in grade 12 (last year in high school)
last friday, the IT technician in my school dared me to make a mail server (send and recieve emails)
and he said he can give me all the dns access that i need to make one..

All i know about mailling servers is how to send emails using php.. I made many and i know how to make them secure...

Now i want to build one but i dont know where to start from.. So please tell me what i need to know so that i build a whole mailling server that can send and recieve emails...

Hey... Thanks a lot for the help... This helped a lot... Thanks again!!

Awah Mohamed -5 Junior Poster

hello people.
how are you all doing?
my problem is i have been programming in c++ for almost a year now but i have always used windows with microsoft visual studio and dev c++ but now i discovered that programming in ubuntu is much more fun couz it is way faster than windows.... now the problem is i dont know which compiler i should use... i have never programmed anything in ubuntu apart from a php website that i built 2 month ago...
please help me to solve this problem..
all i need is the compilers i need and where i can get them from..
thats all!
any help will be greatly apreciated!!

Awesome!! Thanks.. Let me try it..

Awah Mohamed -5 Junior Poster

Hi guys, how are you all??
I want your help in writing and auto run code. I mean, a code in c++ that auto runs my c++ based applications so that when ever the pc starts, my programs start as well.
How can i build it?? I have been programming in c++ for the past few month and i made some programs. Now i want to take them to the next level and make them automatically run when the pc goes on..

Please help me guys to write the code.. Any help will be highly apreciated!!