78 Topics
|
|
i have a script which will fetch content from a website, what i wanna do is modify all that links. Suppose: $html = str_get_html('<h2 class="r"><a class="l" href="http://www.example.com/2009/07/page.html" onmousedown="return curwt(this, 'http://www.example.com/2009/07/page.html')">SEO Result Boost <b> </b></a></h2>'); so, is it possible to modify or rewrite it in this way> <h2 class="r"><a class="l" href="http://www.site.com?http://www.example.com/2009/07/page.html">SEO … |
|
My PHP script can fetch content from a div id, but what is the way to filter this fetch data and exclude some of its content which has this div id `<div id="navbar" class="n">content here content here</div>` I have tried with this code but its not working $regex = '#\<div … |
|
I have a problem while creating an xml file in php.I am not getting th root element.But all other elements are been outputted in the result.What might be the reason????Any help would be appreciated.The code is depicted below.order is my root element. <?php $url='success.xml'; //$xml = simplexml_load_file($url); $name = htmlentities($_POST['name']); … |
|
For my code below i use getElementsByTagName('p') to get the values of the paragraphs that the user enters. but for some reason it when i use textNum[0].value it returns undefined. i tested it with textNum.length and the length keeps increasing which means values are being added to the array. not … |
|
Somebody please help me. The page loads fine but when I change the option on select nothing happens. I'm sure it's just a small problem. Your help will go a long way. Thank you in advance. [CODE]<body> <table id="main" width="50%"> <tr> <td><div id="1"></div></td> <td><div id="2"></div></td> <td><div id="3"></div></td> <td><div id="4"></div></td> <td><div … |
|
hi I'm having serious problems with this code. It all started when I tried to use functions. The function easy() works fine when the page loads but the button has stopped calling the check() function. could it be because I have that stored inside another function? I tried placing outside … |
|
Hi, I need some deep knowledge Regex Vs Dom. Is Regex much faster then Dom or not? Like processing speed, reliable or not . If any one share link or article it helpful for me. |
|
Hi guys We have been asked to create a sudoku game using some type of CSS grid framework. I can't find any good explanations as to what a grid framework is. Someone please explain or direct me to an explanation. Regards |
|
[B]Hello guys i have a problem with PHP code and i dont know what is wrong i want to get the content of a website then search for specific tags then take the value of tags , lets say i want to search for example for these tags [/B] <div … |
|
Hi guys, I'm looking for a little help with Apache Xerces. I am currently trying to use Xerces-C++, but I'll soon be using Xerces-Java. As I look the the C++ programming guide and the DOM programming guide, a lot of my questions remain unanswered. The sample codes lack comments on … |
|
I have a slight situation in my app in my jsfiddle. What I want to do which I can't achieve is that I want the functionality of the Option Type, Number of Answers and Answer buttons within each row to match the functionality on top. The problem is that under … |
|
Hi all, I am dealing a small issue. I am missing something silly :). My need is that I want the entire lines between <TABLE> </TABLE> with no modifications. [CODE]<?php $some_string = <<<STR <HR noShade size=2> <TABLE BORDER=0 CELLSPACING=0 CELLPADDING=0 BGCOLOR="" > <TR BGCOLOR="c1ffcc"> <TH ALIGN="LEFT" COLSPAN=22> <font face="Arial,Helvetica,Geneva,Swiss,Verdana" size="2" … |
|
What is happening is that when the user selects the option "True or False" in a particular row, a string is appering in two places where actually it is suppose to appear in one place. If you follow the steps in my fiddle then you will understand what is happening. … |
|
I have a slight situation in my app in my jsfiddle. What I want to do which I can't achieve is that I want the functionality of the Option Type, Number of Answers and Answer buttons within each row to match the functionality on top. The problem is that under … |
|
Hi all, I came across a new issue in curl request with php. I need to fetch a document from other host [url]http://xyz.com/content.html[/url]. I cannot view that page without login credentials. So I have given [url]http://user:pwd@xyz.com/content.html?get1=x&get2=y[/url]. I can send a successfull curl request to that page in a command line … |
|
It makes since that, when working with javascript, document.getElementById() can't find the Id of an object that hasn't yet been added to the DOM, however when I nest document.getElementById() in a function and call it after the object has been created, document.getElementById() still can't find the object. is there a … |
|
Hi All, I installed php 5 in my linux pc. My phpinfo() says libXML support active libXML Version 2.6.23 libXML streams enabled But still I cannot use DOMDocument in my script. When I use it in my script, Class 'DOMDocument' not found in /var/www/html/getcontent_3.php Any pointers will be very much … |
|
Hi All, Just a quick one, My code (Below) works in Internet Explorer, but not in Chrome, Safari or Mozilla Firefox. Not sure why, but would it be possible for someone to point me in the right direction? Thanks! Code attached; [CODE=Javascript]<script language="javascript"> function formAction(flag) { switch (flag){ case "create": … |
|
Hello. My problem is this: I have a table, for which the row and cols number is given by the user. They contai images. Occasionally a cells picture will be changed. The question I have is this: How to do that? I will be able to compute which cell need … |
|
Hey All! I'm having trouble getting the nodeValue of a specific set of nodes. The xml looks like this: [ICODE] <root> <SpecialParameter>Some Text</SpecialParameter> <SpecialInfo someNumber="123456789"></SpecialInfo> <book> <title>Rusty Bedsprings</title> <author>I. P. Knightly</title> </book> <book> <title>Rush To The Out House</title> <author>Willie Makeit</title> </book> </root> [/ICODE] What I need to get are the … |
|
I am starting out with PHP and in my project I'm trying to fetch XML data from a url and parsing it for data. Now the url that I use is being fetched from a webpage and hence I know that it is correct and it exists. Still, when I … |
|
Hi everybody! Well my question is as follows, I need to search for a div with a specific ID using php under wordpress, till now I found images and links, but I need to find a specific div ID and copy it, for now tested with this: [CODE] $html->find('$html->find('#divid');'); $html->find('div[id=divid]');[/CODE] … |
|
Im new to php and have been struggling with this for some time, but I expect its something simple. Basically I have some code below which I want to use to display an events board. -Info for each event comes from a separate xml file for each event. -XML files … |
|
I am selecting an image as part of a html form. Once selected, jQuery assigns a user-defined attribute of the image to a hidden form variable and passes it to form handler. Neat. Problem is when I dynamically add images that can be selected. I am using live function to … |
|
hey people, i have the following problem, i'm setting up a webshop with over 2k items and every 6months the prices are changing(wines) so i was wondering how to import an xml file into a mysql database without having to go in phpmyadmin. this because i don't want the people … |
|
Hi, I have to retrieve data from database and create a XML file, then i have to parse this file and display output in browser. Creating XML file works fine. But parsing is not working. No errors. But output is not displayed in browser. Have submission tomo. Please Please help. … |
|
Hi, I have to retrieve data from database and create a XML file, then i have to parse this file and display output in browser. Creating XML file works fine. But parsing is not working. No errors. But output is not displayed in browser. Have submission tomo. Please Please help. … |
|
I'm construted a php-class where I create and save some elements in an XMLfile. Outside that class I instantiate the class and save it in a _SESSION['obj'] if the session has not been created yet, otherwise I want to get the document back and add new elements to the XMLfile. … |
|
I have this code: I'm trying to have my program download all the images (that contains "jpg") from a site. [CODE]Dim doc As IHTMLDocument2 = DirectCast(WebBrowser1.Document.DomDocument, IHTMLDocument2) Dim imgRange As IHTMLControlRange = DirectCast(DirectCast(doc.body, HTMLBody).createControlRange(), IHTMLControlRange) For Each img As IHTMLImgElement In doc.images If img.nameProp.Contains("jpg") Then imgRange.add(DirectCast(img, IHTMLControlElement)) imgRange.execCommand("Copy", False, Nothing) … |
|
|
I have an XML file that i am parsing using DOM. I dont know why my code is not working. [CODE] <html> <head> <script type="text/javascript"> function loadXMLDoc(dname) { if (window.XMLHttpRequest) xhttp=new XMLHttpRequest(); else xhttp=new ActiveXObject("Microsoft.XMLHTTP"); xhttp.open("GET",dname,false); xhttp.send(); return xhttp.responseXML; } </script> </head> <body style="color:red"> <script type="text/javascript"> xmldoc=loadXMLDoc("food.xml"); document.write(xmldoc.getElementsByTagName("name")[0].childNodes[0].nodeValue); </script> </body> … |
The End.