Member Avatar

I want to echo the url which includes an onlick property. Here is my code below: function royal_sidebutton_body_tag_html() { // get plugin option array and store in a variable $royal_sidebutton_plugin_option_array = get_option( 'royal_sidebutton_plugin_options' ); // fetch individual values from the plugin option variable array $royal_sidebutton_text_for_tab = $royal_sidebutton_plugin_option_array[ 'text_for_tab' ]; $royal_sidebutton_tab_url = /*$royal_sidebutton_plugin_option_array[ 'tab_url' ]; */ 'https://www.example.co.uk">'; $royal_sidebutton_target_blank = $royal_sidebutton_plugin_option_array[ 'target_blank' ]; // set the page target if ($royal_sidebutton_target_blank == '1') { $royal_sidebutton_target_blank = ' target="_blank"'; } // Write HTML to render tab echo '<a href="' . esc_url( $royal_sidebutton_tab_url ) . '"' . $royal_sidebutton_target_blank . '><div id="royal_sidebutton_tab" class="royal_sidebutton_contents royal_sidebutton_left">' . esc_html( …

Member Avatar
0
20
Member Avatar

Hi Guys, Hope you are enjoying the summer! I am having some trouble with the code below. It is feeding blog posts from another website and linking them to a website. The code works fine. However I need to change the hyperlink(uri) to another domain. <li><a href="<?php echo $feed[$i]->uri; ?>" target="_blank"> <div class="feed-link image"><img src="<?php echo $feed[$i]->itemimage; ?>" alt="<?php echo $feed[$i]->title; ?>" width="223" height="148"/></div> <div class="feed-link title"><?php echo $feed[$i]->title; ?></div> <?php $content_for_text = JFilterOutput::cleanText($feed[$i]->content); /*$content_for_text = preg_replace('/&.*?;/', '', $content_for_text);*/ $content_for_text = preg_replace('/&/', '', $content_for_text); $content_for_text = preg_replace('/amp;/', '', $content_for_text); $content_for_text = preg_replace('/#.*?;/', '', $content_for_text); $content_for_text = JHtml::_('string.truncate', $content_for_text, 220); ?> …

0
15
Member Avatar

Hi Guys, I am currently trying to find out what the problem might be [here:](http://5th-floor.co.uk/circle_test/index.html) I basically want the other circle to display the images properly like in the first circle. My code is as below: HTML <head><link rel="stylesheet" type="text/css" href="css/default.css" /><link rel="stylesheet" type="text/css" href="css/component.css" /><script src="js/modernizr.custom.js"></script></head> <div class="container"> <!-- Codrops top bar --> <div class="codrops-top clearfix"> </div><!--/ Codrops top bar --> <header class="clearfix"> </header> <div class="main"> <div id="fc-slideshow" class="fc-slideshow"> <ul class="fc-slides"> <li><img src="images/3.png" /></li> <li><img src="images/4.png" /></li> </ul> </div> </div> <div class="main"> <div id="fc-slideshow_two" class="fc-slideshow_two"> <ul class="fc-slides"> <li><img src="images/3.png" /></li> <li><img src="images/4.png" /></li> </ul> </div> </div> </div><!-- /container --> …

Member Avatar
-1
20
Member Avatar

Hello Guys, I have been hopelessly trying to make the sidebar full height on this site. When the content expands, its height stays the same. [Site](http://www.5th-floor.co.uk/blog) Any idea how I can do that?

Member Avatar
0
27
Member Avatar

Hi Guys, I have added a script to my website template and somehow it does not work. I think this could be due to a JS conflict but when using firebug, I cannot see anything abnormal. Here is the link: [Link](http://www.citylandlord.co.uk) My JS code is as follow $.noConflict(); $(document).ready(function ($) { // Using jQuery Event API v1.3 $('#quote_home').on('click', function() { ga('send', 'event', 'a', 'click', 'quote_home'); }); $('#quote_landlord').on('click', function() { ga('send', 'event', 'a', 'click', 'quote_landlord'); }); $('#quote_lerg').on('click', function() { ga('send', 'event', 'a', 'click', 'quote_lerg'); }); $('#quote_business').on('click', function() { ga('send', 'event', 'a', 'click', 'quote_business'); }); $('#quote_tenant').on('click', function() { ga('send', 'event', 'a', 'click', …

Member Avatar
0
86
Member Avatar

Hi, I converted a as3 file into a html5 file using swiffy tools offered by google. My code is below: var stage = new swiffy.Stage(document.getElementById('swiffycontainer'), swiffyobject, {}); stage.setFlashVars("clickTAG=%%CLICK_URL_ESC%%%%DEST_URL%%"); stage.start(); It works fine but I want to link the stage to a new page. Any idea how I can achieve this? Thanks

0
8
Member Avatar

We have a site which unfortuntely is not responsive. I was asked to make it responsive, however I am faced with a few options 1. Develop/design a new site espacially for mobile use and redirect it when needed 2. It seems that I can use CSS to make the website appear diffrently when on a mobile phone What would you think is the best approach for this?

Member Avatar
1
20
Member Avatar

Hello, I have this code here. I am trying to show the different options with radio box. There is something wrong in my code, however I can't figure out what it is. Any help? <div id="questions"> <p><img src="images/pic_survey.jpg" width="279" height="104" alt=""/></p> <p>Please take our five second survey!</p> <h3 class="hSubtitle">Question 1</h3> <div class="question"> </div> <input type="button" value="Submit" class="bt_send" id="old_votes_send"> </div> <div class="result clearfix"> <h3 class="hSubtitle">Question 1</h3> <div id="canvas-holder"> <canvas id="chart-area" width="200" height="200" style="width: 200px; height: 200px; margin-left:-10px;"> </canvas></div> <ul class="doughnut-legend"> </ul> </div> <script> $(function() { var doughnutData = [] var style = { "1-2 years": { color: "#FDB45C", highlight: "#FFC870" }, …

Member Avatar
0
18
Member Avatar

Hi Guys, I am actually trying to achieve data replication across two databases(SQL). I have researched into different techniques; synchronous vs asynchronous I have seen that there is a way of doing it using PHPMyAdmin however I am wondering if it is synchronous vs asynchronous?

0
8
Member Avatar

Hello, I am developing a database system and as part of a project I have been asked to look into fault tolerance. From what I understand a fault tolerant program is a program that is not vulnerable to errors. Any ideas how I can ensure that the program I am buiding is fault tolerant. My guess is that if I use exeptions for every methods in my classes that will make my system fault tolerant? Thanks

Member Avatar
0
16
Member Avatar

Hi Guys, I have developed a multi language website and basically the urls are all in English. I remember reading an article which mentioned that urls did not much have importance with SEO. I am now starting to wonder if that's really the case? What are you thoughts?

Member Avatar
0
18
Member Avatar

Hi! Basically I am trying to add the graph inside the Jpanel which already exists. I am getting the erorr "adding a window to a container" Here is my code public void displayGraph(){ try{ String sql = "Select pressure, ventilage from statstbl"; DBCon conn = new DBCon(); JDBCCategoryDataset dataset = new JDBCCategoryDataset(conn.connect(),sql); JFreeChart chart = ChartFactory.createLineChart("Chart", "Pressure", "Ventilage", dataset, PlotOrientation.VERTICAL, false, true, true); BarRenderer renderer = null; CategoryPlot plot = null; renderer = new BarRenderer(); ChartFrame frame = new ChartFrame("Statistics",chart); jPanel3.add(frame, BorderLayout.CENTER); jPanel3.validate(); frame.setVisible(true); frame.setSize(500,650); }catch(Exception ex){ JOptionPane.showMessageDialog(null,ex.getMessage(),"Error",JOptionPane.ERROR_MESSAGE); } }

Member Avatar
0
10
Member Avatar

Hi Guys, I am getting an error: Exception in thread "AWT-EventQueue-0" java.lang.NumberFormatException: For input string: "jLabel4" With this code: public void insertCustomer() { Properties conProps = new Properties(); conProps.setProperty("user", "user"); conProps.setProperty("password", "pass"); int q = Integer.parseInt(jLabel4.getText()); try { con = DriverManager.getConnection("jdbc:mysql://91.208.99.2:3379/5thfloor_pos", conProps); con.setTransactionIsolation(Connection.TRANSACTION_SERIALIZABLE); } catch (SQLException ex) { Logger.getLogger(AddProduct.class.getName()).log(Level.SEVERE, null, ex); } String sql = ("INSERT INTO order_prty(customer, barcode, total) VALUES (?,?, ?)"); try { con.setAutoCommit(false); st = (com.mysql.jdbc.PreparedStatement) con.prepareStatement(sql); st.setString(1, customer.getSelectedItem().toString()); st.setString(2, jTextField3.getText().toString()); st.setInt(3,q); st.execute(); st.close(); con.commit(); // JOptionPane.showMessageDialog(null, "saved!"); } catch (Exception se) { se.printStackTrace(); } } Any ideas?

Member Avatar
0
24
Member Avatar

I am trying to retieve the total salaries from a table where the customer name is X. I have the code below however there seems to be an error. public void total(String name){ double totals=0; Properties conProps = new Properties(); conProps.setProperty("user", "user"); conProps.setProperty("password", "pass"); try { con = DriverManager.getConnection("jdbc:mysql://91.208.99.2:3379/link", conProps); con.setTransactionIsolation(Connection.TRANSACTION_SERIALIZABLE); } catch (SQLException ex) { Logger.getLogger(AddProduct.class.getName()).log(Level.SEVERE, null, ex); } String query=("SELECT SUM(salary) FROM orders WHERE cus_name = ?"); try { con.setAutoCommit(false); st = (com.mysql.jdbc.PreparedStatement) con.prepareStatement(query); st.setString(1, name); ResultSet salaries=st.executeQuery(); while (salaries.next()) totals+=salaries.getDouble("salary"); }catch ( SQLException e) { e.printStackTrace(); } System.out.println("Sum of column = " + totals); } I am …

Member Avatar
0
20
Member Avatar

I am developing a software which will connect to the same database as another application. Is there a term for that? Also any tips on what sort of methods I can use?

Member Avatar
0
14
Member Avatar

Hello, I am developing a software(Java, SQL) which will connect to another's system database in order to have an inventory up to date. I have made some reaseach on the best practices to do that but I am sort of lost. I have read about different integration level, I think in my case I am looking at data level integration. Is this referred as Entreprise Application Integration? Any tips on what I could be searching for? Thanks!

0
6
Member Avatar

From what I understand a DBMS is a software that manupulates a database. I am developing a retail checkout system which is link to a SQL database. Is that consideres as a DBMS?

Member Avatar
0
22
Member Avatar

Hu Guys, Sorry, my question might sound silly but how can I embbed a class inside echo "<tr><td><img src='data:image/jpeg;base64," . base64_encode($row['product_img']) . "' alt='' /></td></tr>"; I tried echo '<div class="img"><tr><td><img src='data:image/jpeg;base64," . base64_encode($row['product_img']) . "' alt='' /></div></td></tr>'; But it's not working. Looks like I am doing something now quite right

Member Avatar
0
11
Member Avatar

Hi Guys, I have the piece of code below and somehow when I click on the input to type some test, the page reloads(refresh). <div id="searchi"> <form id="search_box" action="search.php"> <input id="search" type="text" placeholder="Search products..."> <input id="submit" type="submit" value="Search"> </form> </div> My css is as follow: #search { width: 270px; padding: 4px; font: 100% arial, sans-serif; height:30px; background-color: #f8f8f8; border-radius: 35px; border-width: 0px; border-style: solid; border-color: #c4d9df #a4c3ca #83afb7; } #submit { background-color: #eaf8fc; background-image: linear-gradient(#fff, #d4e8ec); border-radius: 35px; border-width: 1px; border-style: solid; border-color: #c4d9df #a4c3ca #83afb7; width: 50px; padding: 4px; font: 100% arial, sans-serif;} #search_box { margin-right: 150px; width:360px; height:40px; …

Member Avatar
0
11
Member Avatar

Hi Guys, I have this piece of code that should basically retrieve the priduct ID and display the producton a different page when clicked. I must be doing something wrong because I keep getting "nothing selected" even though the product ID is selected(also displayed on the url(www....../productview.php?prodid=1) <?php $product_id = $_GET["productID"]; include_once("connect.php"); if ($conn->connect_error) { die("Connection failed: " . $conn->connect_error); } if(!isset($product_id)) { print("No book selected !"); return; } $query_products = "SELECT * FROM items WHERE productID = $product_id"; $query_product_result = mysqli_query($db, $query_products) or die(mysql_error()); $num_rows_products = mysqli_num_rows($query_product_result); ?>

Member Avatar
0
10
Member Avatar

Hi Guys, I have been trying to display the images from the database with the code below. Images are not displayed. <?php while($product_data = mysqli_fetch_array($query_product_result)) { $num_rows_products = $num_rows_products - 1; Print "<div class='image_panel'><a href = 'products.php?prodid=" . $product_data["ID"] . "'><img src='data:image/jpeg;base64," . base64_encode($row['image']) . "' alt='' /></a></div>"; Print "<h2><a href = 'products.php?prodid=" . $product_data["Item_ID"] . "'>" . $product_data["name"] . "</a></h2>"; Print "<ul><li>Price: &pound;" . $product_data["Item_price"] . "</li><li>Availability: "; Print "<p>" . $product_data["description"] . "</p>"; if($num_rows_products > 0) { Print '<div class="cleaner_with_height">&nbsp;</div>'; } } ?>

Member Avatar
0
28
Member Avatar

Hi Guys, I have this script to insert attribute values in the database. When I run it, only the first value of the array is inserted. Could someone help me? <?php require_once('./app/Mage.php'); Mage::app(); $arg_attribute = 'manufacturer'; $manufacturers = array('NW163UA G70-467','NW167UA G70-481','VM113UA G71-333','VR759UA G71-340','VM114UA G71-343','VM110UA G71-347','VM116UA G71-349','VR761UA G71-358','VR760UA G71-400'); $attr_model = Mage::getModel('catalog/resource_eav_attribute'); $attr = $attr_model->loadByCode('catalog_product', $arg_attribute); $attr_id = $attr->getAttributeId(); $option['attribute_id'] = $attr_id; foreach ($manufacturers as $key=>$manufacturer) { $option['value'][$key.'_'.$manufacturer][0] = $manufacturer; } $setup = new Mage_Eav_Model_Entity_Setup('core_setup'); $setup->addAttributeOption($option); ?>

Member Avatar
0
36
Member Avatar

Hi guys, Trying to set up a cron job using [this tutorial](http://www.magentocommerce.com/wiki/how_to_-_import_manufacturers_or_any_other_option_attribute_set) I have replaced {my/magento/install} with my site path and tried to execute it as a unix command. /usr/bin cd /{/var/sites/e/mysite.com}/shell/; php -f attributeimport.php -- --attribute manufacturer --file ../manufacturers.txt; It gives me an error: Error: The command you entered does not appear to be valid or the program does not exist. If it is a script, please create it before setting up the cron job.

Member Avatar
0
23
Member Avatar

Hello! As part of my unversity module, I need to create an ecommerce website. My only problem is that I need images for this website. Does anyone know a website where I can use images for free? Thanks!

Member Avatar
0
28
Member Avatar

Hi guys, I have my website [here](http://nowcommerce.co.uk/) and it is not centered for some reasons. I notice that they are a couple of things wrong but I can't tell what... Any advice?

Member Avatar
0
32
Member Avatar

Hi Guys, I managed to fill the jtable with the table from the database. Now I want to add specific rows from the database table into the jtable. So I have a textfield and a sql statement: So "Select * from tbl where name =?" I want to add all the entries searched for from the textfield to the jtable. I am not sure it make sense? Any idea how I can achieve that? I was thinking of storing all the entries types in to another database table and then display the results but I think there could be an …

Member Avatar
0
15
Member Avatar

Hello, I am trying to connect to a hosted database on netbeans(java). So far I have the following: Connection con = null; Properties conProps = new Properties(); conProps.setProperty("user", "user"); conProps.setProperty("password", "password"); try { con = DriverManager.getConnection("jdbc:mysql://host:3306/dbname", conProps); String sql = ("SELECT * from products"); st = (com.mysql.jdbc.PreparedStatement) con.prepareStatement(sql); st.executeQuery(); rs = st.getResultSet(); So my host looks something like this: XX.XXX.X.XX which represents numbers. I am definelty doing something wrong as it is not connected. I am sure that the host is correct as well as username, password and db name. Error is : com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure The last packet …

Member Avatar
0
31
Member Avatar

Hello Daniwebers! I am trying to insert the values that were selected in a jtable. I know how to display the sql results in a table but don't how to add the selected values into it. Example: only display the items that the users has searched for and add them to the table. **So I have a text field, and all the entries that are typed in this text field(once at a time) needs to be added up to the table.** Any tips how I can achieve that? **I am not asking for any direct code solution just to get …

Member Avatar
0
9
Member Avatar

Hi guys, I wish you can help me. I started working on SEO for this website. [Here](http://www.luxburgvisual.com) When I type in the name on google, I have the first link coming as www.mylink/rss. I am not sure why. I have also redirected the non-www to www link yesterday, when doing a google search I have both results(www and non-www websites) I have also set the prefered website on google, but this has not done anything. Any advice?

0
19
Member Avatar

Basically, the slider does not work on my website. I think that this is due to a javascript conflict however i am not 100% sure about that. I have used firebug and it came up with the error "TypeError: my_glider is undefined" Here is the code: <div class="homepage"> <div id="slider"> <div class="slidercontrolwr-left"> <div class="slidercontrol"> <a href="#" class="aprev" title="Previous" onClick="my_glider.previous();return false;">Previous</a> </div> </div> <div class="slidercontrolwr-right"> <div class="slidercontrol"> <a href="#" class="anext" title="Next" onClick="my_glider.next();return false">next</a> </div> </div> <div class="scroller"> <div class="content"> <div class="section" id="section1"> <?php echo $this->getLayout()->createBlock('cms/block')->setBlockId('pt001-home-slider1')->toHtml() ?> </div> <div class="section" id="section2"> <?php echo $this->getLayout()->createBlock('cms/block')->setBlockId('pt001-home-slider2')->toHtml() ?> </div> <div class="section" id="section3"> <?php echo $this->getLayout()->createBlock('cms/block')->setBlockId('pt001-home-slider3')->toHtml() …

Member Avatar
0
17

The End.