xhtml

Store Selenium HTML Source Code into element of type HTMLDocument

徘徊边缘 提交于 2019-12-13 05:13:54
问题 Is it possible to store the HTML source grabbed with Selenium (using Excel VBA) into a HTMLDocument element? This is an example using Microsoft Internet Controls and Microsoft HTML Object Library to automate Internet Explorer. Dim IE as InternetExplorer Dim HTML as HTMLDocument Set IE = New InternetExplorer ie.navigate "www.google.com" set HTML = IE.Document can the same be dome with Selenium? For example something like (not working!): Dim selenium As SeleniumWrapper.WebDriver Set selenium =

Element inside class CSS definition not applied using ITextSharp (5.5.1) XHTML to PDF

感情迁移 提交于 2019-12-13 05:04:41
问题 Update: ITextSharp 5.5.2 Supports this feature but previous version of ITextSharp do not. Does ITextSharp 5.5.1 support Class Element CSS selectors? Such as <style> .test td { border: 1px solid green; } </style> I'm getting a result like this When it should be something like If not how would I go about achieving the same results? Using the following code I do not get the desired results. byte[] bytes; Document document = new Document(); using (var memoryStream = new MemoryStream()) using (var

REGEX for only data and end tag

不问归期 提交于 2019-12-13 04:56:29
问题 I am looking for REGEX which will give me data along with the end tag e.g. input: ----------------- <p>ABC<p> ----------------- Output would be ----------------- ABC<p> ----------------- it will only remove the first para para tag,Not for the second para tag and all text in between would be same. I want to mention here that i am looking for <p>ABC<p> not for <p>ABC</p> Its for specific text file having irregular tags Example: i have big xhtml file like... <p>scet</p> <p>sunny </p> <p> <!-

Editable Form and save changes

↘锁芯ラ 提交于 2019-12-13 04:36:36
问题 I'm hoping this isn't harder than it seems. I want to create an HTML form with a few text boxes that will allow people to enter in some data and I want these changes to be saved to the form. For example, if my html page says: Name: [ ] ...I want someone to be able to click on the [] and enter their name, etc. and click SAVE and then have the form say: Name: "Name of Person" If someone wants to update that, they can click on the person's name and change it and click SAVE and have the HTML form

How to make overlap tab effect, without using image?

筅森魡賤 提交于 2019-12-13 04:11:56
问题 How to overlap selected tab over 2nd level tab using css only? This is HTML code <div class="tabcontainer" id="tabcontainer"> <ul id="tabitemscontainer1"> <li class="selected"><a href="#">item 1</a> <ul class="level2"> <li><a href="#">sub item 1 </a></li> <li> <a href="#">subitem 2</a></li> </ul> </li> <li><a href="#">item2</a></li> </ul> </div> I wrote this CSS #tabcontainer { height:62px; position:relative;} #tabitemscontainer1 > li { -moz-border-radius:7px 7px 0 0; background:none repeat

Remove a value from a querystring

走远了吗. 提交于 2019-12-13 03:41:54
问题 I have a URL in which a querystring is produced by a PHP script. Various values are displayed in the querystring. Basically, I need to remove a specific value from the query string when a visitor clicks on a link or a 'remove' button. So, the querystring looks like this: http://www.foo.com/script.php?bar1=green&bar2=blue But when a link or 'remove' button is clicked by a user, bar1=green is removed, and the visitor is directed to the following URL: http://www.foo.com/script.php?bar2=blue I

replace <img> tag's src attribute from file content in rails

佐手、 提交于 2019-12-13 03:34:30
问题 Want to replace tag's src attribute value in xhtml file content. section_content = section.export_xhtml_content file_path doc = Nokogiri::HTML(section_content) unless doc.css('div.image_content').blank? doc.css('div.image_content img').each do |img| newsrc = File.basename img[:src] img.set_attribute('src', newsrc) end end Here src attribute get replaced. But getting XML Parsing Error: XML or text declaration not at start of entity error. After replacing src attribute, resultant content should

Would it be better to combine print css with main css or using another CSS file for print would be better?

百般思念 提交于 2019-12-13 02:26:40
问题 Which way is prefer ed and why to use for print, another css file with media="print" or @media print {....} in same file? 回答1: If you handle a lot of traffic, then a separate file with a separate link would be a better approach...why send that print CSS when so few people will actually need it? 回答2: Depends on how many styles your original file has how many styles will be for printing only how much you think the two parts will expand how much traffic you get (use another page) how likely

Getting a JavaObject out of a JSObject

隐身守侯 提交于 2019-12-13 02:18:43
问题 I have a Javascript function in my xhtml page that does the following: HTML FILE: function getData(){ var data = document.getElementById('data'); return data; } <input type="hidden" value="#{bean.bytes}"/> Backing Bean Code: public class Bean{ public byte[] getBytes(){ return this.bytes; } } And I have an applet that needs to get this byte array from the html Applet code: public class TestApplet extends Applet{ JSObject win = JSObject.getWindow(this); JSObject returnedValue = win.call(

How to prevent the vertical scroll of this div?

泄露秘密 提交于 2019-12-13 02:15:27
问题 I am not so into CSS and I have the following problem. I have the following situation: into a page I have a very large table (that was horizontally truncated because it not entered in the page). So to solve this issue I put this table into a scrollable div, something like this: <div style="overflow-x: scroll;"> // Into this div there is my original table </div> So I have used the overflow-x: scroll; property because I want that the content of the div is only horizontally scrollable (not