Jump to content

shwetapandit

Members
  • Posts

    42
  • Joined

  • Last visited

shwetapandit's Achievements

Member

Member (2/5)

0

Reputation

  1. I am using WPSQT plugin in my blog site .I code some files in PHP also.how to add that files in plugin files.
  2. i tried to search but can't get satisfy.what is the exact difference b/w shopping cart and e-commerce website.Thanks in advance.....
  3. hi..... As i am newbie to wordpress.i may be wrong.but can't find.Below is my files: cutom_page.php <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" /> <title>Untitled Document</title> <style type='css'> <link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_url'); ?>" media="screen" /> <?php if(is_page_template('custom_page.php')) :?> <link rel="stylesheet" type="text/css" href="<?php bloginfo('template_directory'); ?>/style.css" media="screen" /> <?php endif;?> </style> </head> <body> <?php /** * Template Name:Custom Page * The main template file * * This is the most generic template file in a WordPress theme and one of the * two required files for a theme (the other being style.css). * It is used to display a page when nothing more specific matches a query. * For example, it puts together the home page when no home.php file exists. * * @link http://codex.wordpress.org/Template_Hierarchy * * @package WordPress * @subpackage Twenty_Thirteen * @since Twenty Thirteen 1.0 */ ?> <div id="container"> <div id="header"> <h1>Main Title of Web Page</h1></div> <div id="menu"> <b>Menu</b><br> HTML<br> CSS<br> JavaScript</div> <div id="content"> Content goes here</div> <div id="footer"> Copyright©</div> </div> </body> </html> style.css /* CSS Document */ /* Theme Name: Demo Theme URI: http://example.com/Demo/ Description: Demo Author: John Doe Author URI: http://example.com Version: 1.0.0 * ---------------------------------------------------------------------------- */ h1{color:#00FF99; background-color:#00FF66; font:Verdana, Arial, Helvetica, sans-serif; font-size:16px; } p{ color:#FFFF33; background-color:#CCCCCC; } #footer{ background-color:#FFA500; clear:both; text-align:center; } #main{ width:1000px; height:1000px; } #header{ background-color:#FFA500; height:100px; } #menu{ background-color:#FFD700; height:800px; width:200px; float:left; } #content{ background-color:#EEEEEE; height:800px; width:800px; float:left; } header.php <?php /** * The Header template for our theme * * Displays all of the <head> section and everything up till <div id="main"> * * @package WordPress * @subpackage Twenty_Thirteen * @since Twenty Thirteen 1.0 */ ?><!DOCTYPE html> <!--[if IE 7]> <html class="ie ie7" <?php language_attributes(); ?>> <![endif]--> <!--[if IE 8]> <html class="ie ie8" <?php language_attributes(); ?>> <![endif]--> <!--[if !(IE 7) | !(IE ]><!--> <html <?php language_attributes(); ?>> <!--<![endif]--> <head> <meta charset="<?php bloginfo( 'charset' ); ?>"> <meta name="viewport" content="width=device-width"> <title><?php wp_title( '|', true, 'right' ); ?></title> <link rel="stylesheet" type="text/css" href="<?php bloginfo('stylesheet_url'); ?>" media="screen" /> <?php if(is_page_template('custom_page.php')) :?> <link rel="stylesheet" type="text/css" href="<?php bloginfo('template_directory'); ?>/style.css" media="screen" /> <?php endif;?> <!--[if lt IE 9]> <script src="<?php echo get_template_directory_uri(); ?>/js/html5.js"></script> <![endif]--> <?php wp_head(); ?> </head> <body <?php body_class(); ?>> <div id="page" class="hfeed site"> <header id="masthead" class="site-header" role="banner"> <a class="home-link" href="<?php echo esc_url( home_url( '/' ) ); ?>" title="<?php echo esc_attr( get_bloginfo( 'name', 'display' ) ); ?>" rel="home"> <h1 class="site-title"><?php bloginfo( 'name' ); ?></h1> <h2 class="site-description"><?php bloginfo( 'description' ); ?></h2> </a> <div id="navbar" class="navbar"> <nav id="site-navigation" class="navigation main-navigation" role="navigation"> <h3 class="menu-toggle"><?php _e( 'Menu', 'twentythirteen' ); ?></h3> <a class="screen-reader-text skip-link" href="#content" title="<?php esc_attr_e( 'Skip to content', 'twentythirteen' ); ?>"><?php _e( 'Skip to content', 'twentythirteen' ); ?></a> <?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_class' => 'nav-menu' ) ); ?> <?php get_search_form(); ?> </nav><!-- #site-navigation --> </div><!-- #navbar --> </header><!-- #masthead --> <div id="main" class="site-main"> Where i am wrong plz suggest.Thanks in advance...........
  4. where to link and how to link style.css in my custom page template in wordpress.plz reply
  5. as i m newbee to wordpress can anyone tell me what i have to study or my task next. i have installed and upload wordpress i understand admin side and user side functionalite worked on dashboard understand folder structure and file structure of wordpress create a child theme of twenty.thirteen what's next move now
  6. <html> <head> <script src="http://localhost:81/assignment/ckeditor/ckeditor.js"></script> </head> <body> <div style='padding-top:50px'> CKEDITOR: <div> <div> <?php $conn=mysql_connect("localhost","root","")or die(mysql_error()); mysql_select_db("regis")or die(mysql_error()); $p_id=$_GET['p_id']; $query=mysql_query("SELECT p_content FROM admin_page WHERE p_id='$p_id'")or die(mysql_error()); $row=mysql_fetch_array($query,MYSQL_ASSOC); ?> <textarea cols="80" id="p_content" name="p_content" rows="10" > <?php echo $row['p_content']; ?> </textarea> </div> <script type='text/javascript'> CKEDITOR.replace( 'p_content' ); </script> </body> </html>
  7. i did it....... <html> <head> <script src="../ckeditor.js"></script> </head> <?php $conn=mysql_connect("localhost","root","")or die(mysql_error()); mysql_select_db("regis")or die(mysql_error()); print_r($_GET); $p_id=$_GET['p_id']; $query=mysql_query("SELECT p_content FROM admin_page WHERE p_id='$p_id'")or die(mysql_error()); $row=mysql_fetch_array($query,MYSQL_ASSOC); ?> <textarea cols="80" id="p_content" name="p_content" rows="10" > <?php echo $row['p_content']; ?> </textarea> //print_r ($row['p_content']); </html>
  8. i did it now........ <html> <head> <script src="../ckeditor.js"></script> </head> <?php $conn=mysql_connect("localhost","root","")or die(mysql_error()); mysql_select_db("regis")or die(mysql_error()); print_r($_GET); $p_id=$_GET['p_id']; $query=mysql_query("SELECT p_content FROM admin_page WHERE p_id='$p_id'")or die(mysql_error()); $row=mysql_fetch_array($query,MYSQL_ASSOC); ?> <textarea cols="80" id="p_content" name="p_content" rows="10" > <?php echo $row['p_content']; ?> </textarea> //print_r ($row['p_content']); </html>
  9. how to display the textarea content from database using ckeditor. i did it with php as below and it works perfect but how to do same in ckeditor.Any idea.......: <html> <head> //<script src="../ckeditor.js"></script> </head> <?php $conn=mysql_connect("localhost","root","")or die(mysql_error()); mysql_select_db("regis")or die(mysql_error()); print_r($_GET); $p_id=$_GET['p_id']; $query=mysql_query("SELECT p_content FROM admin_page WHERE p_id='$p_id'")or die(mysql_error()); $row=mysql_fetch_array($query,MYSQL_ASSOC); print_r ($row['p_content']); ?> </html>
  10. thanks for help. i got it now.But how to display the textarea content from database using ckeditor.
  11. If ANyone uses CK editor then plz help me i m in great trouble.i download ck editor from the site and after unzip the folder paste all the files where my PHP files are.But can't find how to use it.any help is greatly appreciated.
  12. whwn i tried to print $_GET array it does not print anything while i am sending p_id through URL.Why it is so...... <?php $conn=mysql_connect("localhost","root","")or die(mysql_error()); mysql_select_db("regis")or die(mysql_error()); $query=mysql_query("SELECT * FROM admin_page")or die(mysql_error()); //$row=mysql_fetch_array($query); echo "<table width='500' cellspacing='0' cellpadding='0' border='0'>"; echo "<tr align='centre' colspan='1' rowspan='1'><th>p_name</th><th>p_link</th><th>p_content</th></tr>"; while($row=mysql_fetch_array($query)){ $p_id=$row['p_id']; echo "<tr><td>"; $link=$row['p_name']; print "<a href=".'show_page.php?p_id=$p_id'.">" .$row['p_name'] . "</a><br>"; echo "</td><td>"; echo $row['p_link']; echo "</td></tr>"; } echo "<tr><td>"; echo "</table>"; print_r($_GET); ?>
  13. there is some problem with my code but i couldn't find it.its telling invalid file while i tried with .jpg file which is allowed extension in this file any help is greatly appreciated......... html code: <html> <body> <form action="upload_filee.php" method="post" enctype="multipart/form-data"> <label for="file">Filename:</label> <input type="file" name="file" id="file"><br> <input type="submit" name="submit" value="Submit"> </form> </body> </html> upload_filee.php: <?php $allowedExts = array("gif", "jpeg", "jpg", "png"); $temp = explode(".", $_FILES["file"]["name"]); $extension = end($temp); print_r($_FILES); if ((($_FILES["file"]["type"] == "image/gif") || ($_FILES["file"]["type"] == "image/jpeg") || ($_FILES["file"]["type"] == "image/jpg") || ($_FILES["file"]["type"] == "image/pjpeg") || ($_FILES["file"]["type"] == "image/x-png") || ($_FILES["file"]["type"] == "image/png")) //&& ($_FILES["file"]["size"] < 20000000) && in_array($extension, $allowedExts)) { print_r($_FILES); if ($_FILES["file"]["error"] > 0) { echo "Error: " . $_FILES["file"]["error"] . "<br>"; } else { echo "Upload: " . $_FILES["file"]["name"] . "<br>"; echo "Type: " . $_FILES["file"]["type"] . "<br>"; echo "Size: " . ($_FILES["file"]["size"] / 1024) . " kB<br>"; echo "Stored in: " . $_FILES["file"]["tmp_name"]; } } else { echo "Invalid file"; } ?>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.