473,566 Members | 3,342 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

write php code inside xslt file

2 New Member
i have an xslt file. i have no problem writing html code inside it but when i write a mysql select query inside it, it gives error. Is there any way to write php code inside xslt file?

ratna
Nov 11 '08 #1
1 4418
Dormilich
8,658 Recognized Expert Moderator Expert
that depends whether you want the php code executed in the xslt file or in the result file.

for the former save your file with the .php extension since it is no longer a xslt file. for the latter use <xsl:processi ng-instruction>.

regards
Nov 11 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

6
2699
by: dSchwartz | last post by:
What I think I'm looking for is a way (in XSL stylesheet) to get the contents of a directory. How can this be accomplished? more detailed: /root index.aspx xsl_style.xsl /xml newsletter_001.xml
1
18892
by: Mark Richards | last post by:
The solutions for the following problems seems to be simple but I did not found a (convenient) solution: Assume we have a number of elements of the same type under a common parent e.g. <person ... myattr="aaa">Paul</person> <person ... myattr="bbb">Peter</person> <person ... myattr="ccc">Karl</person> ..... <person ......
1
1349
by: Max Evans | last post by:
I have a XML file, which contains itemid-elements, e.g.: <itemid>3</itemid> <itemid>12</itemid> Now I want to convert these IDs to the corresponding name via XSLT. I thought I could do it this way (XSLT): <xsl:apply-templates select="itemid" /> <xsl:template match="itemid"> <xsl:value-of select="itemnames" /> </xsl:template> And I'd like...
4
1668
by: Bill Nguyen | last post by:
I wonder if I can write to an XML file using column structure (and column names) of an SQLserver table. for example: Table A: column1 int column2 char(30) column3 date XML output:
2
1669
by: ba.hons | last post by:
Hello. I have built a windows service that has a filewatcher object, which checks when any XML files have been created or deleted from a certain directory. My problem now is i have to get involved with the XML ! which am new at!
1
2503
by: Shrek | last post by:
My xslt file contains a passed parameters <xsl;param name="Widths">70px,70px,70px,100px,100px</xsl;param> which I want to use to sets the widths of my table columns . when I create my table I make the following call. <tr> <th valign="bottom" width="{foo:GetWidth(0)}">Length<br/>(units)</th>
0
1721
by: pbd22 | last post by:
Hi. I am new to this... I want to be able to load the output of an XSLT script in a DIV when the user clicks on the appropriate link. I can get the XSLT as its own page fine, but how do I get it when I want to put it inside two DIV tags of another HTML page? I understand the XSLT is server-side. I am guessing that the solution here is to...
3
2532
by: Dmitri Fedoruk | last post by:
Hello everyone, I'm developing a mod_python application that is based on XML\XSLT transforming. I used 4Suite libraries for that, but as the speed was unacceptable for me, I switched to lxml. Everything became much easier and 10 times faster, but I've encountered the subject problem. In brief - all my data and xslt are stored and...
11
3973
by: ianoble | last post by:
I've been trying to piece together various code snippets to create a lookup table inside my xslt without the need for a supplemental xml file. Here is what I have so far. As of now, it does not return anything in the output. I would love to be able to query the xref:factor table to retrieve the value of xref:factor/lookup <?xml...
0
7673
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
8109
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7645
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
7953
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6263
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5213
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3643
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3626
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1202
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.