Hello all
I have the following xml file:
<xfa:data>
<form1>
<Page1>
<Page2>
<contractInfo> ... </contractInfo>
<paymentInfo> ... </paymentInfo>
</form1>
<commercialType> .... </commercialType>
<userList> ... </userList>
<officesList> ... </officesList>
<commercialType> .... </commercialType>
<userLi...
I have a structure I need to visualize. It contains of a set of nodes, where each node has a connection to one of the other nodes. A treeview can not show this as the connection does not follow a treeview structure.
Does anyone know of a control that might be able to show this? The best way to illustrate the node connections is like whe...
I had a crazy (but so crazy that it just might work) idea where every element on a page is created in javascript but given an ID which is a hash of its path in the DOM.
So instead of searching through the DOM to find an element, you hash the path and then getElementById() with that hash.
Problem with this is getting the path might be...
I have been using hook_alter to modify forms in a custom PHP module. I started to take the same approach modifying the result page of "node add" form. However this page is not a form so I don't have a form ID to hook on to. Actually it contains a login form, but that does not contain the elements that I am looking for.
Next I cloned th...
I have a footer that I am adding to a masterpage. Within this footer, if constructs menus based on the Current Node of the sitemap, however the sitemap is coming back as null. Does anyone know how to fix this issue.
Thank you
...
Is there a more efficient way to write the following appendChild / nesting code?
var sasDom, sasDomHider;
var d = document;
var docBody = d.getElementsByTagName("body")[0];
var newNode = d.createElement('span');
var secondNode = d.createElement('span');
// Hider dom
newNode.setAttribute("id", "sasHider");
docBody.appendChild(newNode);
...
I'm copying a range from the page and pasting it back elsewhere, but this becomes problematic when it includes a piece of the page that I don't want to copy. Is there a good way to remove nodes from a range by id? Or if not, in the event that there are two nodes on the page with the same id, is there any way to identify one over the othe...
Is there a way to remove the id attribute of every node in a range or fragment?
Update: I finally found out that the bug I'm struggling with is based on a <[script]> being included in a range, and therefore unexpectedly cloned, when a chrome user does a ctrl+a. My goal would be to remove any instance of <[script]> from the range (or doc...
Hi.
This is the same question of this link:
http://stackoverflow.com/questions/1515722/removing-nidn-in-nodereference-autocomplete
According with the first answer (Grayside) I've created my own module and activated. Then I create a new content, I look sth up in the nodereference field and finally select it -> it works (Doesn't appear ...
Hello all
I need to transform a piece of XML, so that the value of every node in a list I specify is set to "0"
for example:
<contract>
<customerName>foo</customerName>
<contractID />
<customerID>912</customerID>
<countryCode/>
<cityCode>7823</cityCode>
</contract>
would be transformed into
<contract>
<customerName>foo</custo...
I have a bit complicated task.
1. I need to create a node with employee working hours (it's gonna be created for all users with role "employee"), which looks like this:
Monday: From __ : __ To __ : __
Tuesday: From __ : __ To __ : __
Wednesday: From __ : __ To __ : __
etc.
So, I'll have to create probably 14 CCK ...
My current project requires locating an array of strings within an element's text content, then wrapping those matching strings in <a> elements using JavaScript (requirements simplified here for clarity). I need to avoid jQuery if at all possible - at least including the full library.
For example, given this block of HTML:
<div>
<p>T...
HI Guys,
I have a java code to read XML nodes, I want to add in the addition and want to read the parent node value also.
my XML file sample is below:
<breakfast_menu><food id=1><name> Belgian Waffles </name><price> $5.95 </price><description> two of our famous Belgian Waffles with plenty of real maple syrup </description><calories>...
I'm creating elements (level 1) dynamically which in turn create elements (level 2) themselves. However, the children of level 2 elements have "body" as their parent.
In the HTML code below, the content if spotAd2 is created by my function createNode(). It's a Google Ad Sense tag. However, the Google Ad Sense tag create elements that we...
I've got a node, I want it's menu. As far as I can tell, node_load doesn't include it. Obviously, it's trivial to write a query to find it based on the path node/nid, but is there a Drupal Way to do it?
...
I have this xml model.
link text
So I have to add some node (see the text commented) to this file.
How I can do it?
I have writed this partial code but it doesn't work:
xmldoc=minidom.parse(directory)
child = xmldoc.createElement("map")
for node in xmldoc.getElementsByTagName("Environment"):
node.appendChild(child)
Thanks in ad...
I'm looking for a way to gather all of the text in a jQuery wrapped set, but I need to create spaces between sibling nodes that have no text nodes between them.
For example, consider this HTML:
<div>
<ul>
<li>List item #1.</li><li>List item #2.</li><li>List item #3.</li>
</ul>
</div>
If I simply use jQuery's text() method to ...
I have an XML file like this:
<A>
<B>
<c>1<c/>
<d>2<d/>
<e>3<e/>
</B>
<B>
<c>11<c/>
<d>22<d/>
<e>33<e/>
</B>
</A>
Say I wanted to delete the second node. How would I do this?
I have not written code to do this yet. I've researched online but was not able to find just what I'm looking to do. My progr...
From http://search.cpan.org/~pajas/XML-LibXML-1.70/lib/XML/LibXML/Node.pod:
find evaluates the XPath 1.0 expression using the current node as the context of the expression, and returns the result depending on what type of result the XPath expression had. For example, the XPath "1 * 3 + 52" results in a XML::LibXML::Number object bein...
Hi friends,
I'm new at drupal.
I created custom content type with CCK. Added some Phone, Address, Fax fields... Now I'm editing the related node. but in the node it just says print $content How can I use the custom fields I've created? maybe something like print $field_name ? anything like that?
appreciate helps!!!!!
...