עבור לתוכן
View in the app

A better way to browse. Learn more.

HWzone

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

בעיה בPHP וMYSQL

Featured Replies

פורסם

אהלן חברים , נתקעתי בבעיה שאני לא יודע איך לפתור אותה , זה הקוד :

$link = mysql_connect("localhost" , "root" , "") or die(mysql_error()); 
mysql_select_db("samples", $link) or die(mysql_error());
$check = mysql_query("SELECT adress FROM samples_info WHERE adress = '$_POST[adress]' SET NAMES 'hebrew'" , $link);
if(mysql_num_rows($check) == 0)

בכל פעם שאני מריץ את הקוד זה נותן לי את השגיאה :

Warning: mysql_num_rows() expects parameter 1 to be resource, boolean given in J:\wamp\www\sample_upload.php[

מה עושים ??? ?

פורסם
  • מחבר

---הקפצה---

מישהו ?

פורסם

הודעת השגיאה אומרת שהמשתנה check מקבל ערך בוליאני (false) ולא מה שאתה מצפה שהוא יקבל וזאת בגלל שהשאילתה שלך שגויה.

השורה:

$check = mysql_query("SELECT adress FROM samples_info WHERE adress = '$_POST[adress]' SET NAMES 'hebrew'" , $link);

צריכה להיות משהו כזה:

$check = mysql_query("SELECT adress FROM samples_info WHERE adress = '".$_POST["adress"]."'" , $link);

ואם אתה באמת צריך את ה-set names אז תן אותו בפקודה נפרדת אחרי שאתה יוצר את ה-connection.

ארכיון

דיון זה הועבר לארכיון ולא ניתן להוסיף בו תגובות חדשות.

דיונים חדשים

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.