78 Topics

Member Avatar for
Member Avatar for rakibtg

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 …

Member Avatar for rakibtg
0
541
Member Avatar for rakibtg

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 …

Member Avatar for rakibtg
0
872
Member Avatar for bavenbabu

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']); …

Member Avatar for bavenbabu
0
169
Member Avatar for knitex

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 …

Member Avatar for AleMonteiro
0
237
Member Avatar for Que336

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 …

Member Avatar for jstfsklh211
0
232
Member Avatar for Que336

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 …

Member Avatar for Troy III
0
1K
Member Avatar for Aamit

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.

Member Avatar for pritaeas
0
171
Member Avatar for Que336

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

Member Avatar for pritaeas
0
69
Member Avatar for OsaMasw

[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 …

Member Avatar for OsaMasw
0
609
Member Avatar for jsparger

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 …

0
98
Member Avatar for sachinmaster

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 …

Member Avatar for AleMonteiro
0
320
Member Avatar for sugumarclick

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" …

Member Avatar for pritaeas
0
198
Member Avatar for sachinmaster

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. …

Member Avatar for Fest3er
0
144
Member Avatar for sachinmaster

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 …

Member Avatar for sachinmaster
0
133
Member Avatar for sugumarclick

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 …

Member Avatar for sugumarclick
0
5K
Member Avatar for deshazer.jad

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 …

Member Avatar for deshazer.jad
0
162
Member Avatar for sugumarclick

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 …

Member Avatar for cereal
0
931
Member Avatar for Coyx

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": …

Member Avatar for Coyx
0
377
Member Avatar for Psyho

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 …

Member Avatar for MartinRinehart
0
148
Member Avatar for ppetree

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 …

Member Avatar for iamthwee
0
180
Member Avatar for sid78669

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 …

Member Avatar for sid78669
0
252
Member Avatar for bipies

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] …

Member Avatar for bipies
0
502
Member Avatar for NuGG

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 …

Member Avatar for NuGG
0
213
Member Avatar for thekiddy

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 …

Member Avatar for Airshow
0
671
Member Avatar for thijscream

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 …

Member Avatar for jonnysmiths
0
641
Member Avatar for shruwin

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. …

Member Avatar for peter_budo
0
701
Member Avatar for shruwin

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. …

0
68
Member Avatar for mossa

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. …

Member Avatar for mossa
0
317
Member Avatar for serph09

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) …

Member Avatar for codeorder
0
131
Member Avatar for vijiraghs

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> …

Member Avatar for tinymark
0
158

The End.