Hi everyone,
I know this is an old post but ....
Start the New thread then. Let the old one die natural death :)
Hi everyone,
I know this is an old post but ....
Start the New thread then. Let the old one die natural death :)
Hi all,
I'm kinda newbie at this. But I was just wondering where are you placing this code? On every page? or just on the main login page, etc? Thanks
Mike
Put it on separate page and include it on every page needed!
How do you delete Emails? Do you list Emails with link to delete or one fills address and the form submission does delete?
If you list Emails, add Id to delete link. If you use form, that is easy. Since email is unique it can be used instead of ID!
But when i change the ...username = '$username'"); it gives me an empty row.
I always use something like this, and it works!
$sql = "SELECT * FROM users WHERE username='{$username}' AND password='{$password}'";
I gues no shortcut,
Learn HTML/CSS-->JS-->PHP-->MySQL and if you want AJAX
Then you can opt to go to frameworks if you want.
Practice is what makes you good programmer. Note, there is security issues, and that is different beast altogether :)
Check for loop by huhh7 but testing if the modulo (%) brings zero it is divisible by 10 the do whatever you want, that is
for($i=0; $i<=100; i++){
if($i%10==0){
//do whatever it is tenth step
}
}
Completely untested :)
sanitize ALL input data.
It is huge process actually. I plan to do little series on security by the end of this month, God willing (Not expert at all but learning) But here is my suggestion on angles to check:
1. As ardav pointed out, always suspect user - Sanitize and validate ALL external data
2. Secure your session and site against CSRF, XSS and other common attacks
3. Escape all outputs
4. Guard your Database against SQL injection
5. Add DoD, that is in case one thing is compromised (like session variable) then intruder can still be delayed to get in
6. Log all login attempts and if username applies lock after several attempts and alert user with unlock link. If user does not exist, send email to admin.
Actually there are more to that but those are the one I can think for a moment
i want to use internet through mobile on my laptop in ubuntu 10.10. is there any software for it?
what kind of phone? Please try the trick and comment there if anything goes wrong so that Others may benefit there!
nice share!
that's what i need.
You can comment here or there whatever thing you would like to see whether it be Linux (I use Ubuntu) and Programming (Java, Python, C++ or PHP) or any ranting on techie things. I think after June 27th I will be back and post more stuffs and put more links ;)
Thanks for heads up though :)
Thanks everybody. Let me digets the explanations and linked articles.
I will be back in case of question or anything I fail to understand.
Again, thanks a lot :)
Read this. It has very good explanation.
Thanks a lot. I'm reading it now:)
EDIT:
It is nut :(, are you kidding?
Game programming. Software Development --> Game Development.
Oooops!
Sorry, I didn't knew that was the right forum (don't remember to be there!)
If Mod will help me move it there I'll be grateful :(
Order by sorts in ascending order by default, so your code would return the first three, not the last three.
you are right ;)
mysql_query("SELECT * FROM `table` ORDER BY date_Column_Name DESC LIMIT= {$no_days_ago}");
also untested
if you want three latest regardless of date you could go with some query like
$no_days_ago = 3; //or take it from a search box
mysql_query("SELECT * FROM `table` ORDER BY date_Column_Name LIMIT= {$no_days_ago}");
Not tested though ;)
parse the urls and search for image extensions like jpg, gif, et al
session_start(); -->Should be at very top of the file, before anything else. That is the best practice to avoid headers already sent error!
try rectifying this and post any error/warning you get
Hi,
I have a question and I apologize if it is too newbish. I have been for a while now trying to learn OpenGL but I cannot understand how its coordinate systems works. I know coordinate geometry as I did some math long ago as well as equations (linear, polynomial et al) which I think are enough to get me started with math of OGL. But I cannot get hold of how OGL maps its coordinates system with respect to the screen of the computer.
Google was of little help on this and any link/Explanation is warmly welcome and appreciated.
Thanks!
I recomend you Codelobster PHP Edition.
It's most powerful among free code editors.
Some advantages of this editor are: intellectual autocomplete, FTP,
folding code, navigation with Ctrl for all links and descriptions and
incremental searching
Important feature of this editor is presence of special plugins for
Drupal CMS, Joomla CMS, Smarty template engine, JQuery library, CodeIgniter framework,
CakePHP framework, Facebook social network and WordPress blogging platform.Also i want to pay your attention to the option Portable
http://www.codelobster.com
Cannot beat Netbeans or Aptana both of which are free!
Thanks a lot.
Just another question, is there anyone who has used shoutcast?
To make twitter you need to be a girl.
:-O
Thanks Friends.
@Chrishea,
I'm looking at the link
@Ardav,
Is it hard to set up?
More explanations: It is going to be public web broadcast, do number of people will depend how popular it will be
Thanks again!
I am stupid writer. :)
I don't know of stupid boy who can write what you wrote. You just "slipped" ;)
Every programming languages have their own taste and own pretty structures. With my opinion, there is only two options. 1,) Programming for the windows application, 2.) Programming for the web application.
The number 1 is related with software engineering. You can choose many languages such C, C++, C#, Java, and so on. They are primarily pretend to develop the windows (desktop application)..
Why not number two also? When I do PHP/MySQL I use almost all design/techniques I use for desktop apps. May be I'm a bit unprofessional?
I would suggest you start with Python, strange mh? Nope! It will teach you good coding style, and basics of programming. Then to do web app you have choice to learn PHP (they are both interpreted so not much PHP specifics to learn) or go for Python frameworks like the famed django. I would say stay away from Java, given your explanation above. It is overkill ;)
So I was asked to integrate live webcasting in the next version of this website and I have no Idea. I did little reasearch and bump, I only hit shoutcast.
May I ask anyone with Idea on good webcasting software for live internet Audio and video broadcasts to throw out. Something like Software X (free) software Y (commercial)
Thanks!
Thanks budddies, I found HTML purifier filter. Do anyone know how Strong it is? And How to set My editor to produce BBCode? and how do I convert BBCode to HTML so that I can display it in a browser?
Thanks!
would you put sample data on table and ask your question based on minimal data? I have not catch well your question!
what do you have in hand? memeber Id?
I have not understood your question but I think you might need to check table joining, especially inner join. May be explaining what you want to accomplish might help!
That is somehow discussed by Chris in his great article:
http://shiflett.org/articles/the-truth-about-sessions
So you need to put more explanations.
are you PHP developer? You can search each function and get explanations from php manual!
Hint:
offer a form with old password, new passowrd and retype password. If old password matched the current db password and new pass and retyped pass match then update db to reflect new password!
which line?
I changed it to hid. but it is still giving me that error.
I would advice that you learn JS library for all your JS operations. JQuery is on top of my recommendation list!
you mean you want to store hashes on user machine? If yes that is bad Idea. Store the hashes in Database and compare with hashes of the password user enters. Also you can think of moving to SHA2 family, particularly SHA512 as SHA1 is no longer what it used to be. Salting, validating and all defenses are out of your current question!
Hello,
I was reading web security stuffs and found that user can inject malicious codes mostly JS in forms. Now, What about CKFinder/TinyMCE et al? They obviously produce html and any stripping will destroy the article formatting. bad enough they have a "code mode" where user can enter html directly.
Suppose my system is compromised (which is security thinking), what guards can I put to ensure minimum damage?
Thanks :)
Learn AJAX. It will be essential!
I'm back...
Welcome back, Davey!
http://msdn.microsoft.com/en-us/library/ms684847%28v=vs.85%29.aspx
http://www.codersource.net/win32/win32-threads/multithreading-in-win32.aspx
I use wxWidgets so I'm encapsulated against win32 things
My Gosh,when i saw this thread i thought the worst Dani..... (On another site im on we just lost the admin.. (She passed away) and we are all very saddend by this.....)
I am sorry Davey is going thru this but im glad he hasnt left us... (Knock on wood)
Congrats Julienne,i know you will do as good a job as David Did :)
Peace and love to all :)
Last month we thought we had lost Davey as he was going through some tough personal times. Thankfully though, he has announced that he will resume his role and should be back in full force within the coming weeks. During his absence, the role of community admin was placed in the capable hands of Narue, another DaniWeb legend who has been with us since the beginning of time. Happily, once happygeek returns, we'll have two super stars guiding the ship.
DW News Letter
Cheeeerssss!
Thanks Cuonic For Your Help I Will try It
Thanks I Love The Function Thing
Can You Write The Full Function Code For Me Plz
Including The DB Code To Select The Table And Column
It is just a normal connect and query Ops
if it is solved, mark it so ;)
Hello,
Those errors I am facing when I try to connect with MySQL Administrator GUI(MySQL WorkBench). MySQL server is working. In server, MyphpAdmin is installed and then I installed Mysql server and then Mysql Administrator. MySQL command prompt is working but GUI is not working and when I try to login, I am facing those errors which I attached before.
That have something to do with installation than PHP/MySQL. Just uninstall the whole thing and reinstall it!
You want the title stored in your database to appear as the page title if I understood correctly :
<?php $page = 1; //page ID //Connect to Server $title_query = mysql_query("SELECT title FROM table_name WHERE page='$page'"); list($page_title) = mysql_fetch_row($title_query); ?> <head> <title><?php echo $page_title; ?></title> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <link href="http://www.e-alriyadh.com/favicon.ico" rel="icon" type="image/x-icon" /> <link rel="stylesheet" type="text/css" href="Style.Css" /> </head>
If he uses this, he have to put it on top of each page. The function thing is easy and reflects any change to all pages it is included!
I wonder how you guys understood the question. Am I that dumb?
Next time take time to read at least the top of the forum
http://www.daniweb.com/web-development/php/threads/191031
You mean scripts pretends intelligence? If so apply captcha and some advanced mechanism of filtering spams. Without your code, those words are enough I guess ;)