335 Posted Topics

Member Avatar for chaitu11

Here is a simple class that uses mysql to get you started. This was just showing you an example.. you would need to sanitize the data and do some validation checking. class Crud { public function edit($data = array(), $row_id) { $query = mysql_query("UPDATE `table_name` SET field_name='{$data['value']}', field_name='{$data['value']}', field_name='{$data['value']}' WHERE …

Member Avatar for gabrielcastillo
0
1K
Member Avatar for archie.herbias
Member Avatar for gabrielcastillo
0
132
Member Avatar for softmohaideen

Can you post more information? Are you using javascript and php or just php?

Member Avatar for diafol
0
64
Member Avatar for vizz

Maybe this artical will help what you are looking for. [Artical](http://codemug.com/html/custom-scrollbars-using-css/)

Member Avatar for vizz
0
92
Member Avatar for crysys

I think you can use: document.write('<a href="#">'); //rest of the code here document.write('</a>');

Member Avatar for gabrielcastillo
0
163
Member Avatar for lortech

Your mail function is not correct. Example: $to = $_POST['user_email']; $subject = "Password Recovery"; $message = "<b>Password Recovery Program.</b>"; $message .= "<p>New Password: ".$gen_rand_pass."</p>"; $header = "From:no-reply@somedomain.com \r\n"; $header .= "MIME-Version: 1.0\r\n"; $header .= "Content-type: text/html\r\n"; $retval = mail ($to,$subject,$message,$header); if( $retval == true ) { echo "Message sent successfully..."; …

Member Avatar for Kamal_5
0
357
Member Avatar for Silviu_1

looks like your html is broken.. but to answer your question you should use some div's. for the section you are talking about I would split into two divs and float them next to one another. Example: #left-div {float:left; width:50%;} #right-div {float:left; width:50%} .clearFix {clear:both;} <div id="left-div"> <label>TEXT</label> <textarea cols="" …

Member Avatar for Silviu_1
0
117
Member Avatar for mwenyenia07

you could create a function and use the function inside your input Example: function checked_array($id) { $array_items = array('1','2','3','4','5'); foreach($array_items as $item){ if($item == $id){ echo 'checked="checked"; } } } <input type="checkbox" name="item[]" value="" <?php checked_array('2'); ?> />

Member Avatar for gabrielcastillo
0
210
Member Avatar for ryanwhite17
Member Avatar for veedeoo

Hey, was anyone ever able to find the slides? I when to the url provided but got nothing.

Member Avatar for veedeoo
0
957
Member Avatar for skyyadav

Try this: $results = $query->result() // Object $results = $query->result_array(); //Array foreach($results as $row){ echo $row['value']; // array method echo $row->value; // Object method }

Member Avatar for gabrielcastillo
0
329
Member Avatar for shehnaz20

Im writting this on the fly. I haven't tested it, but should get you started. As mentioned above, storing encrypted passwords is how things are done. This script will create a new password and update the database, then send the new password to the user. if(isset($_POST['recover_password']){ if(isset($_POST['user_id']) && isset($_POST['user_email'])){ $pattern …

Member Avatar for gabrielcastillo
0
1K
Member Avatar for saucy6969

you would have to ftp into the site or goto the directory as follow: wp-content/plugins/woocommerce/assets/css/ You are better off creating a custom.css file and making the changes there.. then include the custom .css file within the header file.

Member Avatar for midynamics
0
173
Member Avatar for centenond

Change your br tags `<br />` You really don't need brake tags after div's.. divs are block elements. If you want spacing between div's you should use CSS styling. Looks like you are missing a forward slash in your href. `<font>` is not really used anymore. should use CSS style …

Member Avatar for centenond
0
258
Member Avatar for Demerit
Member Avatar for lily123

`SELECT * FROM table WHERE date_created BETWEEN $date1 AND $date2`

Member Avatar for gabrielcastillo
-2
166
Member Avatar for SimonIoa

What are you trying to save to the database? the path string or the photo itself. if you are saving the path, you need to post the upload processing code for us to review. If you are saving the photo into the database, you need to use blob in the …

Member Avatar for diafol
0
176
Member Avatar for mbarandao

What are you using to generate the array? Maybe you could change the way the array is created. like so.. array('name' => 'value');

Member Avatar for mbarandao
0
226
Member Avatar for gyno

you could try installing mysql workbench.. This will install mysql server on your system and you can create your database's with the workbench.

Member Avatar for gyno
0
277
Member Avatar for centenond

I did this and got a list of file within my clientportal directory, try a forward slash in your path before images and make dirformroot an array. foreach(glob('/www/ci/clientportal/{*.php,*.html,*.sql}',GLOB_BRACE) as $num => $dirr){ $dirroot[] = $dirr; } var_dump($dirroot); exit; Results: array (size=2) 0 => string '/www/ci/clientportal/index.php' (length=30) 1 => string '/www/ci/clientportal/cp_client_portal-barebones.sql' …

Member Avatar for centenond
0
192
Member Avatar for SPRINGHEEL

you could also check is session email is set if(isset($_SESSION['email']){ $email = $_SESSION['email']; $query = mysql_query("SELECT * FROM table_name WHERE email = '$email' "); if(!$query){ die('Query Failed!'.mysql_error()); } $return = mysql_fetch_assoc($query); }

Member Avatar for gabrielcastillo
0
129
Member Avatar for davy_yg

Try this for your upload path. $upload_path = $_SERVER['DOCUMENT_ROOT'] . '/uploads/'; if(!file_exists($upload_path){ mkdir($upload_path); }

Member Avatar for SimonIoa
0
366
Member Avatar for centenond
Member Avatar for centenond
0
592
Member Avatar for abhijit_2

Well you could use a plugin to add to your header.php file. or you could create a slider and place the code in the header.php file. If you are making a custom theme you should find a slider that you like and incorporate into you theme. You should create a …

Member Avatar for gabrielcastillo
0
185
Member Avatar for narasimha.chowdary.75

Depending on the code you are using, inside your textarea you need to echo out the value of the saved textarea.. same goes for text fields

Member Avatar for gabrielcastillo
0
102
Member Avatar for Refrigerator

I believe your query is wrong. If you want to increment the count when a user clicks you would need to add count plus 1 $query = mysql_query("UPDATE count SET count = (count + 1) WHERE username = '$username'"); //Check if query has ran. if(!$query){ die('Error with query').mysql_error(); }

Member Avatar for gabrielcastillo
0
300
Member Avatar for HiHe

This new act is bs... let me decide what I want to do about my heath care, let me decide who has access to my personal information, let me decide who I want to give my money too. Penalty or jail for not signing up with a load a crap.. …

Member Avatar for mike_2000_17
1
858
Member Avatar for davy_yg

Well to answer his qustion so he can stop: in CodeIgniter redirect(); is basiclly just a what the name says.. redirect.. you can insert a params to controll how you want to redirect. Example: redirect('/'); = redirect back to main domain. or redirect('dashboard'); = redirect back to the dashboard page.

Member Avatar for davy_yg
0
321
Member Avatar for accra

Try this: var svreg = document.getElementById("getautomobile").value; var svreg2 = documnet.getElementById('getautomobile2').values; http.open("GET", url + escape(svreg) + "&param=" + escape(svreg2), true); Personally I would use jquery.Jquery makes it realy easy to use ajax. jQuery(document).ready(function($){ $.post('someurl', {param1: $('#id1').val(), param2: $('#id2').val();}).done(function(data){ console.log(data); }); });

Member Avatar for gabrielcastillo
0
227
Member Avatar for Ancient Dragon
Member Avatar for chrisschristou

This should redirect on any server.. If it should fail, I believe it will have to do with your redirect string. `header("Location: " . $insertGoTo); exit();`

Member Avatar for chrisschristou
0
1K
Member Avatar for liza_1

Can you be more specific? What are you looking for? How to create a login page?

Member Avatar for EvolutionFallen
0
214
Member Avatar for annyangel

change your fetchData method public function fetchData() { $sql = " select * from desc_tbl"; $res = mysql_query($sql); $data = array(); while($row = mysql_fetch_assoc($res)){ $data[] = $row; } retrun $data; } in your test.php you can then create a table that will echo out the fetchData()

Member Avatar for Lsmjudoka
0
215
Member Avatar for davy_yg

looks like your database library is not loaded. You can autoload in the config/ directory in the autoload.php file.. you can add database to the $autoload['libraries'] array(). Or your can call the library by itself. In my opinion your controller and models are a bit complicated. Here is how I …

Member Avatar for davy_yg
0
336
Member Avatar for Amaina

Here is what I would do to improve your code a bit. database data output: echo '<table border="1"> <thead> <tr> <th>&nbsp;</th> <th>ID</th> <th>TITLE</th> <th>AUTHOR</th> <th>SECONDARY TITLE</th> <th>YEAR</th> <th>VOLUME</th> <th>NUMBER</th> <th>PAGES</th> </tr> </thead> <tbody>'; while($row = $sql->fetch()){ echo '<tr>'; echo '<td><input type="checkbox" name="checkbox[]" value="'.$row['id'].'" /></td>'; echo '<td>'.$row['title'].'</td>'; echo '<td>'.$row['author'].'</td>'; echo '<td>'.$row['secondar_title'].'</td>'; …

Member Avatar for Amaina
0
909
Member Avatar for Angelo_1

Here is a simple example of how you would go about setting this up. This code is old style of mysql, you would be better off using PDO. You can see the database settings are defined at the top, then the mysql connection is made using the settings. After the …

Member Avatar for gabrielcastillo
0
141
Member Avatar for vinson89

looks like you need to run another query after user has activated the membership. He is a short example, note: mysql_insert_id() will be removed in future version of php.. As diafol suggested, you should move to pdo or mysqli if(!$result){ //Run Error code }else{ $new_id = mysql_insert_id(); $new_member = mysql_query("INSERT …

Member Avatar for gabrielcastillo
0
208
Member Avatar for rhodoscoder

Have you thought about using jquery or some javascript to check your input fields before sending? I would combine javascript and php methods to ensure your data is secure. Looking at your code your need to fix a couple of things with your if statement. Checking if $_POST is empty …

Member Avatar for Eagle.Avik
0
179
Member Avatar for lillorme

If you would like to have all records displayed you need to use a while loop or a foreach loop. echo '<div>'; while($row = mysql_fetch_array($stm, $conn)){ echo '<p>row: '.$row.'</p>'; } echo '</div>'; This loop will produce. <div> <p>row: 1</p> <p>row: 2</p> <p>row: 3</p> <p>row: 4</p> <p>row: 5</p> <p>row: 6</p> <p>row: …

Member Avatar for phaneendrahari
0
280
Member Avatar for kcrazy

My vote would be to use codeigniter for a beginner, then move over to something more heavy like Zend. Codeigniter is very easy to user and has a small learning curve. A person could build a dynamic website with codeigniter in about four to five hours depending on complexity.

Member Avatar for jkon
0
443
Member Avatar for dwlamb

You could try something like this.. you will need to change the css. I didn't test it out but you can get the just of it. <form action="" method="" /> <h3 class="table-head">Table Header</h3> <div class="table-row"> <label class="row-label">Label</label> <div class="row-input"> <input type="text" name="" value="" /> </div> </div> <div class="table-row"> <label class="row-label">Label</label> …

Member Avatar for TomH.PG
0
290
Member Avatar for ses03

Try this out for your buttons .button-box { float:left; margin-right:20px; margin-bottom:10px; } <div class="button-box"> <input type="submit" name="" value="" /> <input type="hidden" name="" value="" /> </div>

Member Avatar for ses03
0
135
Member Avatar for joshl_1995

How is php to know what javascript is? You should create ajax call and send json back to the server for processing. then you can do `decode_json(args);`

Member Avatar for joshl_1995
0
437
Member Avatar for milkman93

You can use jquery to create a new ajax call and check input values.. if values are null or empty return from php with error message. This is just one way of doing it. $(document).ready(function(){ $("#button").on('click',function(){ var name = $('#name').val(); var email= $('#email').val(); var data = 'name=' + name + …

Member Avatar for milkman93
0
8K
Member Avatar for zglows

you dont need to instanciate a new wp_query if you are in your template fine.. you just need to use query_post() function with arguments. Here is the codex. [link](http://codex.wordpress.org/Function_Reference/query_posts) <?php // The Query query_posts( $args ); // The Loop while ( have_posts() ) : the_post(); echo '<li>'; the_title(); echo '</li>'; …

Member Avatar for gabrielcastillo
0
230
Member Avatar for Shodow

This is known as a white space issue. Somewhere in the code white space is getting outputted. Try using ob_start() after session_start() to flush to your code. I would also recommend taking your database code out from under <head> and move to top of the page into a function. Example: …

Member Avatar for Shodow
0
581
Member Avatar for crc0002

I would suggest try using [Color Box](http://www.jacklmoore.com/colorbox/) and adding your webform with inline html. Then when a user clicks login or add to wishlist the form will popup

Member Avatar for gabrielcastillo
0
69
Member Avatar for Vijaysurya

What are you asking? Are you asking about the addMeta() functions? If you are, look at what you are doing? You are overwriting the first function with the second. If you need to have them displayed on two different pages try adding some logic. if( is_some_page() ){ $response->addMeta('title','something'); }else{ $response->addMeta('title','something'); …

Member Avatar for gabrielcastillo
0
199
Member Avatar for luis_see_me

I somewhat agree with ppl above. I would not use a framework if you are learning to develop. That goes for html, css, php ,jquery... etc. You need to be able to hand code and understand what you are coding first. This is a long process and takes time but …

Member Avatar for Shadizon
0
194
Member Avatar for cheelo007

Im going to say on your first index file, its your db connection. I tested your code and everything worked fine. // Parse the log in form if the user has filled it out and pressed "Log In" if (isset($_POST['username']) && isset($_POST['password'])) { $manager = preg_replace('#[^A-Za-z0-9]#i', '', $_POST['username']); // filter …

Member Avatar for cheelo007
0
383

The End.