Jump to content

divinedesigns1

Members
  • Posts

    1,200
  • Joined

  • Last visited

Everything posted by divinedesigns1

  1. ok so i have been looking up some information about how to add facebook status to a personal website, which i found how too but im still having problems displaying those status onto the website and i keep on getting errors on top of that Warning: file_get_contents(): Unable to find the wrapper "https" - did you forget to enable it when you configured PHP? in C:\wamp\www\Spider 2.0\grind.php on line 34 but i also getting an error stating that theres no error Warning: file_get_contents(https://graph.facebook.com/5/feed?access_token=6): failed to open stream: No error in C:\wamp\www\Spider 2.0\grind.php on line 34 how can i go about fixing these errors? the code <?php//Get the contents of facebook page$FBpage = file_get_contents('https://graph.facebook.com/5/feed?access_token=6');// encode the url$FBpage = urlencode($FBpage);// Interpret the data with JSON$FBdata = json_decode($FBpage);// Loop through the data for each news itemforeach($FBdata->data as $news){// Explode News and Page ID's into 2 Values$StatusID = explode("_", $news->id);echo '<li>';// check for empty statusif(!empty($news->message)){ echo $news->message;}echo '</li>';}?> ill accept all help and hints as usual........thanks in advice
  2. is it possible to insert a facebook/twitter status into your database? then echo it out onto your person page of a website?
  3. i made a query and order the id by desc which pulls the last id which was insert, thats the easiest way for me
  4. hello alllll, btw thank everyone who been helping me.Question: is it possible to get the last inserted id on a different file? say you have you.php which insert everything then u have meme.php which echo out everything, is it possible for meme.php to get the last inserted id? because im trying to do that but im not getting back the last inserted id, instead i got back 0 which means it did not get anything in return so my question is, how can i get the last inserted id on meme.php
  5. oo that was just a general question didnt think i needed to add any code, but i got it working now, the problem im facing now is the black background at the top and bottom, which idk how to fix but working on it. any tip kindly let me know $query = mysqli_query($con, "SELECT * FROM movies ORDER BY vid_id DESC LIMIT 0, 1") or die('Error: ' . mysqli_error($con));if($query){while($row = mysqli_fetch_array($query)){echo '<OBJECT CLASSID="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" WIDTH="640"HEIGHT="440"CODEBASE="http://www.apple.com/qtactivex/qtplugin.cab"><PARAM name="SRC" VALUE="videos/' . $row['movie_id'] . '/' . $row['vid_id'] . '.' . $row['ext'] . '"><PARAM name="AUTOPLAY" VALUE="false"><PARAM name="CONTROLLER" VALUE="false"><EMBED SRC="videos/' . $row['movie_id'] . '/' . $row['vid_id'] . '.' . $row['ext'] . '" WIDTH="640" HEIGHT="480" AUTOPLAY="true" CONTROLLER="true"></EMBED></OBJECT>';}}
  6. hey guys, im having a problem displaying my video using php, i try the <video> tag and <embed> tag but this is not working, im using a m4v, mp4, mpeg, avi, wmv and mov files only, but this isnt working.....anyone know how to i can display these files using either tags? and still be able to use php with it
  7. hey yall, im trying to insert a video from a form but its not inserting, im using the same script and method that i use from my image gallery which worked wonderful so this is what i have so far $error = 'Error: '; if(isset($_GET['valbum_id'])){ $vid = $_GET['valbum_id']; $vget = mysqli_query($con, "SELECT * FROM valbums WHERE valbum_id='$vid'") or die($error . mysqli_error($con)); }elseif(isset($_POST['valbum_id'])){ $vid = $_POST['valbum_id']; $vpost = mysqli_query($con, "SELECT * FROM valbums WHERE valbum_id='$vid'") or die($error . mysqli_error($con)); }else{ echo 'You did not select a album'; } if(isset($_POST['vid_sub'])){ $vupload = $_FILES['vidloader']['name']; $vsize = $_FILES['vidloader']['size']; $vtype = $_FILES['vidloader']['type']; $vtemp = $_FILES['vidloader']['tmp_name']; // define the formats, extension and size $vall = array('mov', 'wmv', 'mp4', 'mpeg', 'flv', 'avi'); $vext = end(explode('.', $vupload)); $vmax = 1073741824; // check if the variable is empty if(empty($vupload)){ echo 'Kindly Select a file'; }elseif(($vtype == $vall)){ echo 'this format is not allow'; }elseif(($vsize > $vmax) || ($vsize < 0)){ echo 'This File is too large, max size is 1 Gigabytes only'; }else{ $vinsert = mysqli_query($con, "INSERT INTO movie VALUES('', '1', '$vid', now(), '$vext')") or die($error . mysqli_error($con)); // move the uploaded file to the main folder $video_id = mysqli_insert_id($con); $video_file = $video_id . '.' . $ext; $dir = move_uploaded_file($vtemp, 'pages/videos/' . $vid . '/' . $video_file); } } i dont have any errors or anything but its not inserting the video into the database nor move the temp video to the folder, can anyone help me here?
  8. oo i got it working using php, but ill keep that in mind tho mad hype thank everyone for the advice, each comment helped em solve my problem
  9. it would but im not good with JS, so im not sure how to go about doing this in that script
  10. ok, sorry if i confused anyone, anyway, theres 2 divs a photomedia and a tinymedia......the photomedia displays anything that is clicked in the tinymedia using the $_GET[] function, but instead of the thumbnails in the tinymedia being displayed in the photomedia once i clicked it, the thumbnail is being displayed in a new window/tab. which isnt what im trying to do. to give a better picture, the gallery suppose to have 1 big photo and a set of thumbnails below it, and once you click on any of the thumbnail a bigger version of that thumbnail suppose to display where the big photo is set. but im not getting it to do that exactly, i got the photos to display but when i try clicking on the thumbnail it doesnt display in the photomedia div
  11. the image displays, like i said, when i click on the thumbnail it doesnt display in the rite place
  12. the link isnt broken it just wouldnt display in the photomedia div when i click it in the tinymedia
  13. <?php$query = mysqli_query($con, "SELECT * FROM images WHERE page_id='1' LIMIT 0, 1") or die('Error: ' . mysqli_error($con));if($query){while($row = mysqli_fetch_array($query)){ echo '<a href="admin/pages/images/' . $row['page_id'] . '/' . $row['image_id'] . '.' . $row['ext'] . '"><img src="admin/pages/images/' . $row['page_id'] . '/' . $row['image_id'] . '.' . $row['ext'] . '" alt="Artist" width="600" height="377" /></a>';}}?></div><div id="tinymedia"><?php$query2 = mysqli_query($con, "SELECT * FROM images WHERE page_id='1'") or die('Error: ' . mysqli_error($con));if($query2){ while($row1 = mysqli_fetch_array($query2)){ echo '<a href="admin/pages/images/' . $row1['page_id'] . '/' . $row1['image_id'] . '.' . $row1['ext'] . '"><img src="admin/pages/images/' . $row1['page_id'] . '/' . $row1['image_id'] . '.' . $row1['ext'] . '" alt="Artist" width="101" height="91" /></a>'; }}?> but when i try to use the $_GET[] function its doesnt even work, it just open the picture of the thumbnail in a new window which i dont want to be happening
  14. divinedesigns1

    Need help

    hey guys im trying to get the image of a certain page to display into a div but i cant get the image to display, can someone give me a hint,
  15. like when i submit the form i keep on getting duplicates of everything in the email
  16. ok thanks, i know i had to use the id and get but thanks for explainning it to me now to create it
  17. hello, i keep having duplication on my form when i get the email it be like yawn yawn etc code is below <?php@$fn = $_POST['firstname'];@$ln = $_POST['lastname'];@$email = $_POST['email'];@$come = $_POST['company'];@$sub = $_POST['Subject'];@$enq = $_POST['enqment'];if(isset($_POST['submit'])){if(empty($fn) && empty($ln) && empty($come) && empty($sub) && empty($enq)){ echo 'One or More Fields Are Empty, Please Review & Fill In Those Fields';}elseif(!empty($fn) && empty($ln) && empty($come) && empty($sub) && empty($enq) && empty($email)){ echo 'Last Name </br> Company</br>Subject</br>Enquiry and email is empty, kindly fill these fields to processed';}elseif(!empty($fn) && !empty($ln) && empty($come) && empty($sub) && empty($enq) && empty($email)){ echo 'Company</br>Subject</br>Enquiry and emailis empty, kindly fill these fields to processed';}elseif(!empty($fn) && !empty($ln) && !empty($come) && empty($sub) && empty($enq) && empty($email)){ echo 'Subject, Enquiry and Email is empty, kindly fill these fields to processed';}elseif(!empty($fn) && !empty($ln) && !empty($come) && !empty($sub) && empty($enq) && empty($email)){ echo 'Enquiry and email is empty, kindly fill these fields to processed';}elseif(!empty($fn) && !empty($ln) && !empty($come) && !empty($sub) && !empty($enq) && empty($email)){ echo 'Email is empty, kindly fill these fields to processed!';}elseif(!empty($fn) && !empty($ln) && !empty($come) && !empty($sub) && !empty($enq) && !empty($email)){ $fn = strip_tags($fn) . stripslashes($fn); $ln = strip_tags($ln) . stripslashes($ln); $come = strip_tags($come) . stripslashes($come); $sub = strip_tags($sub) . stripslashes($sub); $enq = strip_tags($enq) . stripslashes($enq); if(filter_var($email, FILTER_VALIDATE_EMAIL) == $email){ echo 'This email address is not valid'; }else{} $to = "dds1@dds1.net"; $subject = $sub; $message = $enq; $from = $email; $headers = "From:" . $email . $fn . $ln; mail($to, $subject, $message, $headers); echo "Your Request have been sent!!!"; $fn = ""; $ln = ""; $email = ""; $come = ""; $sub = ""; $enq = "";}else{ echo 'We were unable to send your request! </br> Kindly make sure all fields are fill and try again';}}?><h3 style="margin-top:10px;">Contact Us</div><div id="forms" style="margin:10px auto 0px auto; width:550px;"><form action="" method="post"><div class="formsone" style="width:100%; margin-bottom:10px;"><label id="title" style="overflow:left; width:150px; text-align:right;">First Name: </label><input name="firstname" type="text" size="35" style="margin-left:40px;" value="<?php echo $fn; ?>" /></div><div class="formsone" style="width:100%; margin-bottom:10px;"><label id="title" style="overflow:left; width:150px; text-align:right;">Last Name: </label><input name="lastname" type="text" size="35" style="margin-left:40px;" value="<?php echo $ln; ?>" /></div><div class="formsone" style="width:100%; margin-bottom:10px;"><label id="title" style="oveflow:left; width:150px; text-align:right;">Email: </label><input name="email" type="email" size="35" style="margin-left:70px;" value="<?php echo $email; ?>" /></div><div class="formsone" style="width:100%; margin-bottom:10px;"><label id="title" style="overflow:left; width:150px; text-align:right;">Company: </label><input name="company" type="text" size="35" style="margin-left:48px;" value="<?php echo $come; ?>" /></div><div class="formsone" style="width:100%; margin-bottom:10px;"><label id="title" style="overflow:left; width:150px; text-align:right;">Subject: </label><input name="Subject" type="text" size="35" style="margin-left:60px;" value="<?php echo $come; ?>" /></div><div class="formsone" style="width:100%; margin-bottom:10px;"><div class="formlabel" style="float:left; width:50px; text-align:right;"><label id="title">Enquiry: </label></div><div class="forminput" style="float:right; width:440px;"><textarea name="enqment" cols="50" rows="10"><?php echo $enq; ?></textarea></div></div><div class="formsone" style="width:100%; text-align:left; clear:both;"><input type="submit" name="submit" id="submit" value="Submit" /></div></form></div>
×
×
  • Create New...