Search Results

Search found 31 results on 2 pages for 'ronedog'.

Page 2/2 | < Previous Page | 1 2 

  • how to use a PHP Constant that gets pulled from a database

    - by Ronedog
    Can you read out the name of a PHP constant from a database and use it inside of a php variable, to display the value of the constant for use in a menu? For example here's what I'm trying to accomplish In SQL: select menu_name AS php_CONSTANT where menu_id=1 the value returned would be L_HOME which is the name of a CONSTANT in a php config page. The php config page looks like this define('L_HOME','Home'); and gets loaded before the database call. The php usage would be $db_returned_constant which has a value of L_HOME that came from the db call, then I would place this into a string such as $string = '<ul><li>' . $db_returned_constant . '</li></ul>' and thus return a string that looks like $string = '<ul><li><a href="#" onclick="path_from_db">Home</a></li></ul>'. To sum up what I'm trying to do Load a config file based on the language preference query the db to return the menu name, which is the name of a CONSTANT in the config file loaded in step one, and also retrieve the menu_link which is used in the "onclick" event. Use a php variable to hold the name of the CONSTANT Place the variable into a string that gets echo'd out to create the menu displaying the value of the CONSTANT. I hope this makes enough sense...is it even possible to use a constant like this? Thanks.

    Read the article

  • MySQL problem reconnecting (mysqld.exe) keeps giving error...

    - by Ronedog
    Need some guidance figuring out what went wrong. I've been using mysql, phpmyadmin for just under a year on my home computer while I develop a webapp. 3 days ago I updated my windows vista with all the "wonderful" microsoft updates, security patches, etc...and now it's broke. I tried uninstalling all the upgrades, but there are 4 of them I can't unistall because microsoft says their "operating system" updates and can't be unistalled. My system is: windows vista, php 5+, mysql 5.1, Apache 2+. I can run my web app and it queries the database without any problems. However, when I run phpmyadmin to get into the database I get an error: "mysqld.exe has stopped working" and phpmyadmin crashes. I tried going to the command line for mysql to do a mysqldump to backup my database and it gives me an error "2013, could not connect to the server". If I restart the computer the webapp will work again. Basically, php can query the database, but if I try to get at the database through phpmyadmin, or the command prompt the mysqld.exe error occurs and blows mysql out. Any ideas what's going on here? Any ideas how to get around this to backup the db, so I can reinstall mysql?. I'm really lost where to start. I don't really know if the updates caused the problem, or if the 4 updates that can't be unistalled are really the problem. Any tips will be appreciated. thanks.

    Read the article

  • css displaying divs inside a Tr fine in FireFox, but IE increases the width of the row...

    - by Ronedog
    I'm having some difficulty figuring out what is going on and how to fix it. I have some divs that contain some icons that are causing a width problem when displaying tabular data. If I remove the div's that contain the icons, the row width ends up the way I want it (See the firefox example below). Here's the view in Firefox which is what I want (notice the positioning of the icons circled in red, which is aligned on the same y coordinate, or thereabouts): Here's the view in IE7 (Notice what happens to the icons and the width of the grey line, which is the table row): Here's the HTML: <table> <tbody> <tr> <td> <span>stuff 1</span> <span>stuff 2</span> <div class="prop_edit"><img class="img_height14" src="edit.jpg"></div> <div class="prop_archive"><img class="img_height14" src="archive.jpg"></div> <div class="prop_delete"><img class="img_height14" src="delete.jpg"></div> <div style="display:none;"> <div>Links Here</div> </div> </td> </tr> </tbody> Heres the CSS: .prop_edit{ float:right; position: relative; top: 0px; right:50px; } .prop_archive{ float:right; position: relative; top: 0px; right:10px; } .prop_delete{ float:right; position: relative; top: 0px; right: -30px; } .img_height14{ height:14px; vertical-align:top; position:relative; } I've tried a bunch of different css things, but really am just hacking away hoping to figure something out. Anyone got some tips that could help me? Thanks in advance.

    Read the article

  • Icon placement relative to list items

    - by Ronedog
    When I show a hidden div that is stored inside an <li> tag the icons are pushing down to the bottom of the <li>. How can I prevent this? Here's the HTML: <ul> <li>Utah <ul> <li>Park City <ul> <li>Park Cat 1 <div><img class="portf_edit" /></div> <div><img class="portf_archive" /></div> <div><img class="portf_delete" /></div> </li> <li>Skiing <div><img class="portf_edit" /></div> <div><img class="portf_archive" /></div> <div><img class="portf_delete" /></div> </li> </ul> </li> </ul> </li> </ul> Here's the li css: li { list-style-type:none; vertical-align: top; list-style-image: none; left:0px; text-align:left; clear: both; } .portf_edit{ float:right; position: relative; right:50px; display:block; } .portf_archive{ float:right; position: relative; right:-5px; display:block; } .portf_delete{ float:right; position: relative; right: -60px; display:block; } Here's a screen shot prior to expanding which shows the icons how I want them to line up: Here's the screen shot prior to expanding which shows where the icons are being pushed to:

    Read the article

  • jquery problem with toggle event only fireing on the 2nd click...

    - by Ronedog
    Can anyone explain why the following jquery only fires the 2nd toggle event and how to fix it? Specifically, every time I click the nested < a element it brings up the alert "2nd click". I tested the selector to make sure it was selecting the element properly and it does, or at least it inserted a class without any problems. The selector is selecting the very last node in the unordered list that has an anchor tag. $("#nav li:not(:has(li)) a").toggle(function() { //1st click alert("1st Click"); }, function() { //2nd click alert("2nd Click"); }); Nested HTML structure that fails: <ul id="nav"> <li> <span>stuff</span> <a href="#">Cat 1</a> <ul> <li> <span>stuff</span> <a href="#">Subcat1</a> <ul> <li> <span>Stuff</span> <a href="#">Subcat Details</a> </li> </ul> </li> </ul> </li> </ul> However, this works right and fires both click events: <ul id="nav"> <li> <span>stuff</span> <a href="#">Cat 1</a> </li> </ul>

    Read the article

  • jquery help assigning multiple mouse events using a .each() to hide/show icons and show background c

    - by Ronedog
    Need some help assigning a mouseover event to display some icons that start out hidden. For every <li> in the ul, I have icons. When the user mouses over the <li> I want the span tag with a class called "icons" to be displayed. When the mouse out event occurs remove the class and/or just hide the span. The problem for me is how to assign event so just the span tag and its contents appear and disapear when the mouse hovers over the <li>. Heres the HTML: <ul id="nav"> <li>Cat 1 <span class="icons"> <div>stuff here</div> </span> </li> <li>Cat 2 <span class="icons"> <div>stuff here</div> </span> <ul> <li>Sub Cat 2A <span class="icons"> <div>2A stuff here</div> </span> </li> </ul> </li> </ul> Heres my jquery code. $('#nav li').each(function(){ //Add Background Shading o Mouseover to all Rows in the menu $(this).mouseover(function(){ $(this).addClass("background_grey").removeClass("icons"); }) $(this).mouseout(function(){ $(this).removeClass("background_grey").addClass("icons"); }); }); Thanks for the help.

    Read the article

< Previous Page | 1 2