₦airaland Forum

Welcome, Guest: RegisterLoginWith GoogleTrendingRecentNew

Stats: 3,325,001 members, 8,419,874 topics. Date: Thursday, 04 June 2026 at 05:51 AM

Toggle theme

Sleepingdemon's Posts

Nairaland ForumSleepingdemon's ProfileSleepingdemon's Posts

1 2 3 4 5 6 (of 6 pages)

Tech JobsRe: A Web Developer Is Needed Urgently. by sleepingdemon: 11:39pm On Jun 15, 2016
duvie92:
Depends, if you use node.js. And isn't JavaScript a web language?
oga, i can bet the op dosent even know what node.js/npm is, im sure the javascript he is talking about does not pass jqwery/javascript, o.p if u know what ejs, handlebars, jade is, ill retract this statement and use multer inside php apps.
Tech JobsRe: A Web Developer Is Needed Urgently. by sleepingdemon: 11:12pm On Jun 14, 2016
The guy sef dey find front end developer, e say na web developer....never knew html, css and Javascript is equals web developer.
ProgrammingRe: Gdevit.com Finally Completed Guys!! by sleepingdemon: 11:46pm On Jun 13, 2016
Abeg, whats the meaning of ALUU.
Seen the site, looks quite cool, but ive not been able to navigate through ot, however theres a possible risk of integer overflow. But its almost nothing to worry about
ProgrammingRe: Phpsocket.io-Real-time Chat Engine With HTML & Android Client Support [Updated] by sleepingdemon: 6:54pm On May 31, 2016
Abeg who wants to start e-war here? without settling boys for street so? this war no go nice if una no settle guys.
Tech JobsRe: Sachng.com Need Serious Partners by sleepingdemon: 11:32am On May 31, 2016
me that ive been saching for davido's baby mama, i no even seen picture of davido talkless of the baby mama
ProgrammingRe: Phpsocket.io-Real-time Chat Engine With HTML & Android Client Support [Updated] by sleepingdemon: 10:51pm On May 30, 2016
Ftc things, space booked...i dedicate this space to my ubuntu 16.04 lts.
ProgrammingRe: Naija Coder: Test Your Coding Skills Now by sleepingdemon: 6:29pm On May 30, 2016
just passing by.....
Tech JobsRe: Sachng.com Need Serious Partners by sleepingdemon: 5:33pm On May 30, 2016
like i once said, he'd better move to mongodb and get better option for the application. looking at php as the forefront engine, talking about being resource hungry, i hope php gets to survive. talking about using hhvm and php are two different things, although they are both written in php, one in converted to c++ to deal with concurrency issues.
Tech JobsRe: Sachng.com Need Serious Partners by sleepingdemon: 12:01pm On May 30, 2016
dhtml18:
as long as this sach remains on php, it shall never ever ever reach 1/100th of bing.
ehen, that remind me, im still waiting for your php websocket version, if its not still documented, u can send without documentation
Tech JobsRe: Sachng.com Need Serious Partners by sleepingdemon: 10:27am On May 30, 2016
land booked. this land is not for sale. when this sach engine big pass bing untop php, i go come build house for here, sorry i meant devilfinder not bing, till then beware of 419, this land is not for sale. beware of dogs too.
ProgrammingRe: My First Real PHP Based Website by sleepingdemon: 12:37pm On May 24, 2016
Op the content of the file you outline is it index1.php?
The class you provided, if ran, would return "you are an oop genius"
the error you are recieving is from the index1.php class, not the class.
besides, i guess you want the file to print out you are an oop genius and also usernames and id gotten from the user table.

if that is the case, ive corrected your class to be like this, and it should work.

But i repeat, the error of exec you are getting is from index1.php, not this file.


<?php
class user{
//inniating variables to be used in db_connect method.
// Database assess values.

public $db_host= "localhost";
public $username="";
public $password= "";
public $db_name="php_database";
public $dbc;
public $sql;
public $row;
public $result;
public $something;

function __construct(){

$this->connect();
}

// method to connect to database
function connect(){
try{

$this->dbc= new PDO("mysql:host=$this->db_host; dbname=$this->db_name;charset=utf8", $this->username, $this->password);
}
catch (PDOException $e){
echo "failed to connect to database pdo ";
echo $e->getmessage();
exit();
}
return $this->dbc;
}




public function dbr(){
$this->sql="SELECT username, id FROM users";

$stmt=$this->dbc->query($this->sql);
return $stmt;
return $stmt->fetchAll(PDO::FETCH_ASSOC);




}
}
$usermanagment= new user();



echo "you are an OOP genius";
echo "<br>";
try {
$answer=$usermanagment->dbr();

foreach ($answer as $row) {
print $row['id'] . "\t";
print $row['username'] . "\n";

}
} catch(PDOException $ex) {
echo $ex->getmessage();
//handle me.
}
echo "<br>";
echo $usermanagment->sql;


?>
ProgrammingRe: How To Roast A Monitor Lizard by sleepingdemon: 7:00am On May 23, 2016
Nmeri17:
op so you're saying, the monitor lizard actually has nothing, to do with my laptop's monitor?
as in ehn, i was hoping he was going to verify the fact that this monitor lizard actually eats the flex of our laptops screen and that is why we should roast it.
ProgrammingRe: PHP Code To Insert And Retrieve Images From Mysql Server by sleepingdemon: 5:53pm On May 18, 2016
grin grin its never that bad, jes buy holandia youghurt before you start building it, before you sip finish, you for don build the eCommerce app.
another tip op, make sure you buy gala too.
ProgrammingRe: A New Search Engine by sleepingdemon: 5:49pm On May 18, 2016
dhtml18:
^^^wait,what kind of search be that now? All me i want is for the search to understand some keywords like:
- goat (top priority e.g. our president is a goat)
- boko haram
- fulani herdsman
- snake
- tiwa savage
after that, then we can talk business!
snake, you must be lala's brother
ProgrammingRe: PHP Code To Insert And Retrieve Images From Mysql Server by sleepingdemon: 9:34am On May 18, 2016
must you store images in database, upload images to a folder in your web root, store the path in the database and your good to go.
but if ure keen in storing the image to database directly, use a blob field in your database, convert image to blob and save in database
ProgrammingRe: A New Search Engine by sleepingdemon: 11:13pm On May 17, 2016
i officially give up on this thread. any other thing i would do here is to read comments, troll and sip the new holandia youghurt...yummy something.
ProgrammingRe: A New Search Engine by sleepingdemon: 10:51pm On May 17, 2016
guru01:
To my understanding, mysql can handle millions of data and is very much scalable.
The only limitation is the app logic, how you code.
mysql uses one connection pool, so if you have 10 users launching your app at the same time, and the 10 isers need to run 100 queries each, mysql lines up the 1000 queries from the 10 users and executes them one after the other.
that said, the 10th user gets his data last and slower. now apply that logic to 1 million users running a query that searches a mysql database of over 40tb of data....
why do you think even mysql enginners wont tell you its scalable, rather they would optimize indexes for faster search time and at the worst, they master - slave replication, which is almost the same thing as data sharding which i mentioned.
i hope this gives u a bit more insight to your understanding.
ProgrammingRe: A New Search Engine by sleepingdemon: 10:22pm On May 17, 2016
micodon:
The very first rule in developing an app is: CHOOSE THE RIGHT TOOL(S) FOR THE JOB. In choosing "THE RIGHT TOOLS", you look at performance, scalabilty, ease of development and others

PHP has been my first choice language for close to a decade now, but TBT its only REALLY good at making websites and some web apps.
Last Year i wrote an eCommerce application with my HIGHLY DECOUPLED PHP framework (a "HELLO WORLD" benchmark gives about 1,300 rps). Benchmarks showed that it ran at about 250rps (Opencart runs at about 60rps). But it starts dropping requests when there are above 500 concurrent users.

I rewrote the same application with GOLANG and it handles over 5 million concurrent requests with breeze at about 6,500 requests per second with less than 15MB or RAM.

The Point? In a PERFORMANCE CRITICAL Application, PHP will fall your hands....It was designed for just short-lived webpages. Here are some reasons why PHP is not suitable for PERFORMANCE CRITICAL APPLICATIONS

1. Blocking I/O
2. No Parallel Processing out of the box
3. No Multi-threading out of the box.
4. Not Suitable for background Tasks (Remember your crawler)
5. Most probably used with Apache which spins up a thread for every request
6. Dies after every request
7. Not good for Computationally Intensive tasks (i.e Search engine analytic, ranking system, etc)
8. Not Memory Efficient
9. Extremely Poor Concurrency Model

In designing and developing your application, NEVER EVER LET THE DEVELOPMENT LANGUAGE IMPLEMENTATION BE YOUR BOTTLENECK...THAT PROBLEM SHOULD BE YOUR DB IMPLEMENTATION.

Should you use PHP now until you have performance or scalability issues? ABSOLUTELY NOT. By the time you get to that problem, you'll have had a huge PHP code-base which would make transitioning to another language NEAR IMPOSSIBLE. If you think i'm lying, ASK FACEBOOK.

JAVA is good (except for the JVM being resource-hungry)
GOLANG has its Limitations but its good
RUST is a new kid on the block, but is EXCEPTIONAL
JULIA,
SCALA (JVM Problem again)
HASKELL
C/C++

One of these could be used in combination with any of the following:
Python
Nodejs (Not a language, but an execution environment)
LUA, etc
op, just in case my oga here has killed you with too much technicals here, the pin point of what he is saying is php dosent handle concurrency very well, and its also having blocking i.o's and for a search engine on the other hand, concurrency is key.
ProgrammingRe: A New Search Engine by sleepingdemon: 10:20pm On May 17, 2016
micodon:
on Android alone, you mean?
yeah yeah, but we all know most people this days learn java only for andriod development.
ProgrammingRe: A New Search Engine by sleepingdemon: 4:43pm On May 17, 2016
dhtml18:
I use many technologies, and i am sure when next i do a review of my skills - MEANSTACK/JAVA should probably top
i'm just here waiting for google to move on to swift so i dont have to hear the name JAVA all the time. i slightly hate that language.
ProgrammingRe: A New Search Engine by sleepingdemon: 4:00pm On May 17, 2016
dhtml18:
Even me that I used to say that PHP is my strongest language (with all my bragado) cannot answer this your question - oya over to the goland and java boys.
Using php and mysql isnt the best choice really because:
To scale PHP on a relational database, you need to shard your data. This means splitting the data by some reasonable key. This might mean East Coast customers go on one RDBMS, Midwest customers go on another, and the West Coast on a third. This is a lot of complexity to swallow when you chose PHP because it was "simple" and "free."
But like i said, till your app grows to when scaling is most needed, its not a bad idea using php alongside a no-sql database not a RDBMS database.
ProgrammingRe: Android Studio Things - Gradle Build In 3 Seconds by sleepingdemon: 2:50pm On May 17, 2016
grin grin grin grin the thing do mistake, e mean 3 hours
ProgrammingRe: Why Is Rails Adoption So Slow In Nigeria? by sleepingdemon: 11:32pm On May 16, 2016
everything rail in nigeria is slowly adapted, even the nigerian railways, so why complain.
ProgrammingRe: A New Search Engine by sleepingdemon: 11:28pm On May 16, 2016
in all of this, that guy that asked you to use golang, i need to flog him very hard. ehen, that advice on java is still fair, on the other hand, what do i know, just in case you're more comfy with php, you can use mongodb as your database instead, when the app outgrows php, you can move to another lang. or if ure a javascript person, mean stack is actually useful.
Tech JobsRe: Urgent Vacancy For PHP Programmer by sleepingdemon: 11:16pm On May 16, 2016
jes passing by and decided to say hi.. abeg i support that guy, what about codeigniter... op better add it to your list before we do street fight for here...
i rest my case.
ProgrammingRe: Simple Python Challenge by sleepingdemon: 9:16pm On May 15, 2016
proxy20:
so confusing what is **
that's raised to the power of, same thing ^ is used for in some other languages
Tech JobsRe: Female Programmer Needed For Collaboration On A Project by sleepingdemon: 6:28pm On May 14, 2016
o.p if i start to dey dress like woman and catwork, i go fit submit my c.v? shey na only because of diversity you need female programmer, make me sef diversify myself for the job.

i expect your prompt response
regards.

the programmer you need
Tech JobsRe: Affordable PHP Programmer Needed by sleepingdemon: 3:08pm On May 14, 2016
hmm, first of all, whats ur range for affordability....someone who charges 1m per project is affordable to some a lot and still not affordable to a few, so by affordable, ure yet to narrow your search, its too ambiguous.
anyways, i get affordable programmer, but yin go use 2and half years complete your project even if na to write script to echo i am here, can he apply too?
Tech JobsRe: Skilled App Programmer That Specialises With Cordova Needed by sleepingdemon: 11:24am On May 12, 2016
proxy20:
socket.io is cool but you need to add more features like group chat , authentication , logout , sendInvites,deleteContacts ,search .sendBroadcast .
that is while building the app itself, the sockets.io is just for real time interaction as fast as that of bbm snd whatsapp...
Tech JobsRe: Web Developers Wanted - Earn Up To N250,000 Per Month (apply Now) by sleepingdemon: 11:22am On May 12, 2016
dhtml18:
^^^See you, if you no put account number for your CV, na how employer wan take pay you? Dont forget to add your BVN number too (just in case)
i go add pension pin join sef

1 2 3 4 5 6 (of 6 pages)