/    Sign up×
Community /Pin to ProfileBookmark

Why wont someting as simple as this work? it’s al blank

include “config.php”;

$open = “SELECT * FROM open WHERE id = ‘1’”;

$result = mysql_query($open);

echo $result[‘openclosed’];[/code]

to post a comment

1 Comments(s)

Copy linkTweet thisAlerts:
@NvenomJul 31.2011 — are u getting any errors?

if not use this
include "config.php";

$open = "SELECT * FROM open WHERE id = '1'";

$result = mysql_query($open) or die(mysql_error());

echo $result['openclosed'];

also make sure the connection is set up right in config.php im guessing thats where your

mysql_connect("", "root", "pass") or die(mysql_error());
mysql_select_db("database") or die(mysql_error());


remember to use the right tags
<?php ?> //USE these Tags
<? ?> //DONT Use these


Help @evania spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 9.27,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ

legal: ({
terms: of use,
privacy: policy
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
recent_tips: (
tipper: @ddiebold17,
tipped: article
amount: 1000 SATS,

tipper: @Mqlinka19,
tipped: live stream
amount: 4900 SATS,

tipper: @Mqlinka19,
tipped: article
amount: 10 SATS,