Search Results

Search found 4604 results on 185 pages for 'utf 8'.

Page 24/185 | < Previous Page | 20 21 22 23 24 25 26 27 28 29 30 31  | Next Page >

  • Turkish characters are not displayed correctly

    - by tfeseas
    MySql database uses utf-8 encoding and data are stored correctly.I use set_name utf8 query to make sure the data called are utf-8 encoded.all variables from database works fine as long as the header charset is utf-8,but the static html characters do not work properly.When i set header charset to ISO-8859-9 variables are displayed differenly while html characters work ok.can anyone help me? <?php header('Content-Type: text/html; charset=ISO-8859-9'); ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head><title>noname</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

    Read the article

  • UnicodeDecodeError in pyton 2.7

    - by user2913962
    i try to write this code to process Arabic language by python import codecs file = codecs.open("C:\Python27\CCA_raw_utf8.txt","r","utf-8") text= file.read() #################################### print "\n "," --------------------------------------------" text=text[1:] words=text.split() for w in words: if w == unicode ("?????","utf-8"): print w but it doesn't and take error " if w == unicode ("?????","utf-8"): UnicodeDecodeError: 'utf8' codec can't decode byte 0xc7 in position 0: invalid continuation byte " why program gives this result and how we can correct that??

    Read the article

  • changing drive nodes & hdparm

    - by Kalamalka Kid
    I am currently attempting to create a command that works at startup to kill the power on two of my very noisy hard drives. I have edited the etc/rc.local file to include this command: sudo hdparm -y /dev/sdc sudo hdparm -y /dev/sdd exit 0 While I think this should work, it seems the allocated drives keep switching around every time I reboot. I have sda, sdb, sdc, sdd, and sde but they keep getting jumbled around (making the drive I wish to shut different than sdd which is making the task of shutting down the right drive on start-up quite cumbersome. I had a perfectly functioning ftstab file working which disappeard, but I restored it from the back up into the etc/ dir: # <file system> <mount point> <type> <options> <dump> <pass> #Entry for /dev/sda1 : UUID=43c09daf-08a5-44f2-89b0-fc7c6f0d1e67 / ext4 errors=remount-ro 0 1 #Entry for /dev/sdd1 : UUID=443AFBAD7FE50945 /media/DX100 ntfs-3g defaults,nosuid,nodev,locale=en_CA.UTF-8 0 0 #Entry for /dev/sdb1 : UUID=FCE456F5E456B21E /media/GalaxyM83 ntfs-3g defaults,nosuid,nodev,locale=en_CA.UTF-8 0 0 #Entry for /dev/sdf1 : UUID=1CA057FDA057DBB8 /media/Holideck ntfs-3g defaults,nosuid,nodev,locale=en_CA.UTF-8 0 0 #Entry for /dev/sdc1 : UUID=7ABB49654B799D40 /media/JX3P ntfs defaults,nosuid,nodev,locale=en_CA.UTF-8 0 0 it seems every time I boot the order of the drives changes. I do not know how to resolve this. A quick workaround the problem was to go with UUID instead of the DEV letter by editing the etc/rc.local file to include: hdparm -y /dev/disk/by-uuid/443AFBAD7FE50945 hdparm -y /dev/disk/by-uuid/7ABB49654B799D40 So I thought I was in the clear, as I heard both hard drives die down during the boot sequence, BUT, as soon as I log in both drives start up again! so now I have to figure out what is making them start up again after log in, or perhaps another way to get them to turn off. Is there some kind of command i can get to execute after log in? I tried editing the startup applications to include an autossh with: autoshh - sudo hdparm -y /dev/disk/by-uuid/7ABB49654B799D40 autoshh - sudo hdparm -y /dev/disk/by-uuid/443AFBAD7FE50945 but this did not seem to work to turn off the disks after log in.

    Read the article

  • Windows Server NTFS volume list file name encodings and any illegal file names

    - by benbradley
    I'm having to deal with a Windows Server (NTFS) file server and our backup application appears to be failing with certain files. According to this https://en.wikipedia.org/wiki/NTFS#Internals NTFS apparently supports file names encoded in UTF-16 but according to their support team, our backup application only supports UTF-8. I'd like to confirm whether this is actually the problem by seeing the file name encoding for myself. The files that are failing appear to be using plain English A-Z letters and other ASCII characters. No accents or non-English letters etc. I suppose even though the letters appear to be plain A-Z the file name could still be encoded in UTF-16. Does anyone know of a utility or script that can recursively go through all files in a directory and show the encoding of the file name? Then I could try renaming to UTF-8 to see if the backup can proceed. I'm not a Windows developer so can't write this up myself. Presumably the encoding of the file name should be stored in the FS somewhere and therefore it should be possible to expose this.

    Read the article

  • Force encoding with IIS 7

    - by Cédric Boivin
    I try to force encoding with IIS 7. When I add in the http response headers the key : Content-Type and value charset=utf-8 i got this key content-type : text/html,content-type=utf-8 it's there a way to remove the comma ? Thanks Justin for your answer. But it's seen don't work. There is my config, i need to do that for asp classic. <?xml version="1.0" encoding="UTF-8"?> <configuration> <system.webServer> <staticContent> <remove fileExtension=".html" /> <remove fileExtension=".hxt" /> <remove fileExtension=".htm" /> <remove fileExtension=".asp" /> <mimeMap fileExtension=".htm" mimeType="text/html" /> <mimeMap fileExtension=".hxt" mimeType="text/html" /> <mimeMap fileExtension=".html" mimeType="text/html" /> <mimeMap fileExtension=".asp" mimeType="text/html; charset=UTF-8" /> </staticContent> </system.webServer> </configuration>

    Read the article

  • Request sent with version Http/0.9

    - by user143224
    I am using common-HttpClient ver 3.1. All my requests are having correct (default) Http version in the request line i.e Http/1.1 except fot 1 request. Following Post request gets the requestline as Http/0.9 server : port/cas/v1/tickets/TGT-1-sUqenNbqUzvkGSWW25lcbaJc0OEcJ6wg5DOj3XDMSwoIBf6s7i-cas-1 Body: service=* I debugged through the httpclient code and saw the requestline is set to http/1.1 but on the server i see the request coming as http/0.9. i tried to set the http version explicitly using the HttpMethodParams but does not help. Does someone has any idea what could be wrong? HttpClient client = new HttpClient(); HostConfiguration hc = client.getHostConfiguration(); hc.setHost(new URI(url, false)); PostMethod method = new PostMethod(); method.setURI(new URI(url, false)); method.getParams().setUriCharset("UTF-8"); method.getParams().setHttpElementCharset("UTF-8"); method.getParams().setContentCharset("UTF-8"); method.getParams().setVersion(HttpVersion.HTTP_1_1); method.addParameter("service", URLEncoder.encode(service, "UTF-8")); method.setPath(contextPath + "/tickets/" + tgt); String respBody = null; int statusCode = client.executeMethod(method); respBody = method.getResponseBodyAsString();

    Read the article

  • C# RegEx - find html tags (div and anchor)

    - by czesio
    Hi I have to retrieve several div section (of specific class name "row ") with it's content, and additionally find all anchor tags (link urls) (with class "underline red bold"). Shortly speaing : get section of: ... (divs, tags ...) and collections of urls string[] urls = {"/searchClickThru? pid=prod56534895&q=&rpos=109181&rpp=10&_dyncharset=UTF-8&sort=&url=/culture-and-gender-intimate-relation-ksiazka,prod56534895,p"} the entire page looks like that: <html> ... a lot of stuff <div class="row "> <div class="photo"> <a rel="nofollow" href="/searchClickThru?pid=prod56534895&amp;q=&amp;rpos=109181&amp;rpp=10&amp;_dyncharset=UTF-8&amp;sort=&amp;url=/culture-and-gender-intimate-relation-ksiazka,prod56534895,p"> <img alt="alt msg" src="/b/s/b9/03/b9038292d147a582add07ee1f0607827.jpg"> </a> </div> <div class="desc"> <div class="l1"> <div class="icons"> </div> <table cellspacing="0" cellpadding="0" border="0"> <tbody> <tr> <td> <div class="fleft"> <a class="underline red bold" href="/searchClickThru?pid=prod56534895&amp;q=&amp;rpos=109181&amp;rpp=10&amp;_dyncharset=UTF-8&amp;sort=&amp;url=/culture-and-gender-intimate-relation-ksiazka,prod56534895,p"> Culture And Gender <br>Intimate Relation</a> </div> <div class="fleft"> </div> </td> </tr> </tbody> </table> </div> <div class="l2"> <div> </div> <div> <div class="but"> </div> </div> </div> <div class="l3"> Long description <a class="underlinepix_red no_wrap" rel="nofollow" href="/searchClickThru?pid=prod56534895&amp;q=&amp;rpos=109181&amp;rpp=10&amp;_dyncharset=UTF-8&amp;sort=&amp;url=/culture-and-gender-intimate-relation-ksiazka,prod56534895,p"> more<img alt="" src="/b/img/arr_red_sm.gif"> </a> </div> </div> </div> <div class="omit"></div> <div class="row "> <div class="photo"> <a rel="nofollow" href="/searchClickThru?pid=prod56534895&amp;q=&amp;rpos=109181&amp;rpp=10&amp;_dyncharset=UTF-8&amp;sort=&amp;url=/culture-and-gender-intimate-relation-ksiazka,prod56534899,p"> <img alt="alt msg" src="/b/s/b9/03/b9038292d147a582add07ee1f06078222.jpg"> </a> </div> <div class="desc"> <div class="l1"> <div class="icons"> </div> <table cellspacing="0" cellpadding="0" border="0"> <tbody> <tr> <td> <div class="fleft"> <a class="underline red bold" href="/searchClickThru?pid=prod56534895&amp;q=&amp;rpos=109181&amp;rpp=10&amp;_dyncharset=UTF-8&amp;sort=&amp;url=/culture-and-gender-intimate-relation-ksiazka,prod5653489225,p"> Culture And Gender <br>Intimate Relation</a> </div> <div class="fleft"> </div> </td> </tr> </tbody> </table> </div> <div class="l2"> <div> </div> <div> <div class="but"> </div> </div> </div> <div class="l3"> Long description <a class="underlinepix_red no_wrap" rel="nofollow" href="/searchClickThru?pid=prod56534895&amp;q=&amp;rpos=109181&amp;rpp=10&amp;_dyncharset=UTF-8&amp;sort=&amp;url=/culture-and-gender-intimate-relation-ksiazka,prod56534895,p"> more<img alt="" src="/b/img/arr_red_sm.gif"> </a> </div> </div> </div> Can anybody help me to create suitable reg ex?

    Read the article

  • How can i make changes to this file Encoding?

    - by SuperUserMan
    I have these 3 files 21/08/2014 07:15 PM 122 Tw2AWK.csv 21/08/2014 07:15 PM 125 Tw2Notepad.csv 21/08/2014 07:15 PM 119 Tw2REPL.csv C:\myfilesfile Tw2AWK.csv TwREPL.csv Tw2Notepad.csv Tw2AWK.csv; UTF-8 Unicode text, with CRLF line terminators Tw2REPL.csv; UTF-8 Unicode text Tw2Notepad.csv; UTF-8 Unicode (with BOM) text, with CRLF line terminators HEX of these files is as follows C:\myfilesxxd -p Tw2REPL.csv 0a222344656c686947616e675261706520776173206120736d616c6c2069 6e636964656e7420746f2023536d616c6c5261706973744a6169746c6579 20646e61696e6469612e636f6d2f696e6469612f7265706f72742d69e280 a6207069632e747769747465722e636f6d2f6762565070776637744f22 C:\myfilesxxd -p Tw2AWK.csv 0d0a222344656c686947616e675261706520776173206120736d616c6c20 696e636964656e7420746f2023536d616c6c5261706973744a6169746c65 7920646e61696e6469612e636f6d2f696e6469612f7265706f72742d69e2 80a6207069632e747769747465722e636f6d2f6762565070776637744f22 0d0a C:\myfilesxxd -p Tw2Notepad.csv efbbbf0d0a222344656c686947616e675261706520776173206120736d61 6c6c20696e636964656e7420746f2023536d616c6c5261706973744a6169 746c657920646e61696e6469612e636f6d2f696e6469612f7265706f7274 2d69e280a6207069632e747769747465722e636f6d2f6762565070776637 744f220d0a I want Tw2REPL.csv to look like Tw2Notepad.csv How can I do it? NOTE: I have do this all via command line (batch) . I can use any 3rd party standalone exe's though. I am on Windows XP Please help, its very important for me

    Read the article

  • Understanding Zabbix Triggers

    - by Mediocre Gopher
    I have zabbix set with an item to monitor a log file on a zabbix client: log["/var/log/program_name/client.log","ERROR:","UTF-8",100] And a trigger to determine when that log file get's more ERRORs: {Template_Linux:log["/var/log/program_name/client.log","ERROR:","UTF-8",100].change(0)}#0 This trigger gets tripped when the log file gets ERRORs the first time, but then that first trigger just sits around for ever in Monitoring-Triggers. My understanding is that the next time the server checks the value of log["/var/log/program_name/client.log","ERROR:","UTF-8",100] and sees that it hasn't changed that the trigger would go away. Obviously this isn't the case. Could someone explain why this first trigger isn't going away? Ultimately my goal is to receive an email whenever ERRORs are added to that log file, but I would like to understand how triggers are working first.

    Read the article

  • xsl:include template with no default namespace causes xmlns=""

    - by CraftyFella
    Hi, I've got a problem with xsl:include and default namespaces which is causing the final xml document contain nodes with the xmlns="" In this synario I have 1 source document which is Plain Old XML and doesn't have a namespace: <?xml version="1.0" encoding="UTF-8"?> <SourceDoc> <Description>Hello I'm the source description</Description> <Description>Hello I'm the source description 2</Description> <Description/> <Title>Hello I'm the title</Title> </SourceDoc> This document is transformed into 2 different xml documents each with their own default namespace. First Document: <?xml version="1.0" encoding="utf-8"?> <OutputDocType1 xmlns="http://MadeupNS1"> <Description >Hello I'm the source description</Description> <Description>Hello I'm the source description 2</Description> <Title>Hello I'm the title</Title> </OutputDocType1> Second Document: <?xml version="1.0" encoding="utf-8"?> <OutputDocType2 xmlns="http://MadeupNS2"> <Description>Hello I'm the source description</Description> <Description>Hello I'm the source description 2</Description> <DocTitle>Hello I'm the title</DocTitle> </OutputDocType2> I want to be able to re-use the template for descriptions in both of the transforms. As it's the same logic for both types of document. To do this I created a template file which was *xsl:include*d in the other 2 transformations: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output indent="yes" method="xml"/> <xsl:template match="Description[. != '']"> <Description> <xsl:value-of select="."/> </Description> </xsl:template> </xsl:stylesheet> Now the problem here is that this shared transformation can't have a default Namespace as it will be different depending on which of the calling transformations calls it. E.g. for First Document Transformation: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"> <xsl:output indent="yes" method="xml"/> <xsl:template match="SourceDoc"> <OutputDocType1 xmlns="http://MadeupNS1"> <xsl:apply-templates select="Description"/> <xsl:if test="Title"> <Title> <xsl:value-of select="Title"/> </Title> </xsl:if> </OutputDocType1> </xsl:template> <xsl:include href="Template.xsl"/> </xsl:stylesheet> This actually outputs it as follows: <?xml version="1.0" encoding="utf-8"?> <OutputDocType1 xmlns="http://MadeupNS1"> <Description xmlns="">Hello I'm the source description</Description> <Description xmlns="">Hello I'm the source description 2</Description> <Title>Hello I'm the title</Title> </OutputDocType1> Here is the problem. On the description Lines I get an xmlns="" Does anyone know how to solve this issue? Thanks Dave

    Read the article

  • CakeDC Users Plugin - I Can't Send Emails

    - by JimBadger
    I apologise for the rambling nature of this question, please bear with me and I'll provide all the extra info needed for you to stop me going mad from failing at something that looks inherently very straightforward... I've just installed CakePHP 2.2, and the first thing I've done is add the cakeDC Users plugin. It's all working, apart from sending an email verification when a user registers. I've tried so many combinations of different things in email.php, that I have now utterly got my knickers in a twist. Whatever I do, when the verification email should be sent, all I get is: No connection could be made because the target machine actively refused it. My email.php currently looks like this: class EmailConfig { public $default = array( 'transport' => 'Smtp', 'from' => '[email protected]', //'charset' => 'utf-8', //'headerCharset' => 'utf-8', ); public $smtp = array( 'transport' => 'Smtp', 'from' => array('Blah <[email protected]>' => 'Chimp'), 'host' => 'ssl://smtp.gmail.com', 'port' => 465, 'timeout' => 30, 'username' => '[email protected]', 'password' => 'secret', 'client' => null, 'log' => false, //'charset' => 'utf-8', //'headerCharset' => 'utf-8', ); public $fast = array( 'from' => '[email protected]', 'sender' => null, 'to' => null, 'cc' => null, 'bcc' => null, 'replyTo' => null, 'readReceipt' => null, 'returnPath' => null, 'messageId' => true, 'subject' => null, 'message' => null, 'headers' => null, 'viewRender' => null, 'template' => false, 'layout' => false, 'viewVars' => null, 'attachments' => null, 'emailFormat' => null, 'transport' => 'Smtp', 'host' => 'blah.net', 'port' => 25, 'timeout' => 30, 'username' => 'user', 'password' => 'secret', 'client' => null, 'log' => true, //'charset' => 'utf-8', //'headerCharset' => 'utf-8', ); } How do I get cakeDC Users plugin to just send a non-SMTP email? Or do I have to use, for example, my Gmail details? But, if I do have to go down the SMTP route, what is wrong with the above? Other info: I'm using the latest version of XAMPP and my PHP install is ssl enabled.

    Read the article

  • Serve up syntactic XHTML5 using the text/html MIME type?

    - by cboettig
    I have a site currently written with HTML5 tags. I'd like to be able to parse the site as XML, with support for namespaces, etc, to facilitate programmatic extraction of data. Currently I have <!DOCTYPE html> and <meta charset="utf-8"> Which I gather is equivalent in HTML5 to explicitly setting the content-types as <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> for my current setup. In order to serve XML it sounds like the right thing to do is <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> Should I also change my Content-Type to <meta http-equiv="content-type" content="application/xhtml+xml; charset=iso-8859-1" /> Or is that not necessary? What is the advantage of having content-type be "application/xhtml+xml"? What is the disadvantage? (Sounds like it may break internet explorer rendering of the site? but maybe that information is out of date now?) Many thanks!

    Read the article

  • Why does Sharepoint 2010 Web Reference work, but Service Reference does not

    - by Darien Ford
    Sharepoint is setup to use NTLM authentication. When I reference http://myserver/Sites/Ops/_vti_bin/Lists.asmx?WSDL as a Web Reference, I can call the methods and get valid responses. When I reference the same url as a Service Reference, the server throws an exception when calling methods. My account is admin on the Sharepoint Farm. This is the app.config for the service reference (mostly auto generated): <?xml version="1.0" encoding="utf-8" ?> <configuration> <configSections> </configSections> <system.serviceModel> <bindings> <basicHttpBinding> <binding name="ListsSoap" closeTimeout="00:01:00" openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferSize="65536" maxBufferPoolSize="524288" maxReceivedMessageSize="65536" messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered" useDefaultWebProxy="true"> <readerQuotas maxDepth="32" maxStringContentLength="8192" maxArrayLength="16384" maxBytesPerRead="4096" maxNameTableCharCount="16384" /> <security mode="TransportCredentialOnly"> <transport clientCredentialType="Ntlm" /> </security> </binding> </basicHttpBinding> </bindings> <client> <endpoint address="http://myserver/Sites/Ops/_vti_bin/Lists.asmx" binding="basicHttpBinding" bindingConfiguration="ListsSoap" contract="SharepointLists.ListsSoap" name="ListsSoap" /> </client> </system.serviceModel> </configuration> Saddly, the only information the exception provides is this: "Exception of type 'Microsoft.SharePoint.SoapServer.SoapServerException' was thrown." No other details. The code that I'm using is: public ListClass() { _Client = new SharepointLists.ListsSoapClient(); } public System.Xml.Linq.XElement GetTaskList() { return _Client.GetList("Tasks"); } Any thoughts? I would like to use the Service Reference rather than the Web Reference. UPDATE: I tried Rob's suggestion and got this error: HTTP GET Error URI: http://myserver/Sites/Ops/_vti_bin/Lists.asmx The document at the url http://myserver/Sites/Ops/_vti_bin/Lists.asmx was not recognized as a known document type. The error message from each known type may help you fix the problem: - Report from 'http://myserver/Sites/Ops/_vti_bin/Lists.asmx' is 'The document format is not recognized (the content type is 'text/html; charset=utf-8').'. - Report from 'DISCO Document' is 'There was an error downloading 'http://myserver/_vti_bin/Lists.asmx?disco'.'. - The request failed with HTTP status 404: Not Found. - Report from 'WSDL Document' is 'The document format is not recognized (the con tent type is 'text/html; charset=utf-8').'. - Report from 'XML Schema' is 'The document format is not recognized (the conten t type is 'text/html; charset=utf-8').'.

    Read the article

  • How do I read Unicode characters from an MS Access 2007 database through Java?

    - by Peter
    In Java, I have written a program that reads a UTF8 text file. The text file contains a SQL query of the SELECT kind. The program then executes the query on the Microsoft Access 2007 database and writes all fields of the first row to a UTF8 text file. The problem I have is when a row is returned that contains unicode characters, such as "?". These characters show up as "?" in the text file. I know that the text files are read and written correctly, because a dummy UTF8 character ("?") is read from the text file containing the SQL query and written to the text file containing the resulting row. The UTF8 character looks correct when the written text file is opened in Notepad, so the reading and writing of the text files are not part of the problem. This is how I connect to the database and how I execute the SQL query: ---- START CODE Connection c = DriverManager.getConnection("jdbc:odbc:Driver={Microsoft Access Driver (*.mdb, *.accdb)};DBQ=C:/database.accdb;Pwd=temp"); ResultSet r = c.createStatement().executeQuery(sql); ---- END CODE I have tried making a charSet property to the Connection but it makes no difference: ---- START CODE Properties p = new Properties(); p.put("charSet", "utf-8"); p.put("lc_ctype", "utf-8"); p.put("encoding", "utf-8"); Connection c = DriverManager.getConnection("...", p); ---- END CODE Tried with "utf8"/"UTF8"/"UTF-8", no difference. If I enter "UTF-16" I get the following exception: "java.lang.IllegalArgumentException: Illegal replacement". Been searching around for hours with no results and now turn my hope to you. Please help! I also accept workaround suggestions. =) What I want to be able to do is to make a Unicode query (for example one that searches for posts that contain the "?" character) and to have results with Unicode characters receieved and saved correctly. Thank you!

    Read the article

  • How to view ASMX SOAP using Fiddler2?

    - by outer join
    Does anyone know if Fiddler can display the raw SOAP messages for ASMX web services? I'm testing a simple web service using both Fiddler2 and Storm and the results vary (Fiddler shows plain xml while Storm shows the SOAP messages). See sample request/responses below: Fiddler2 Request: POST /webservice1.asmx/Test HTTP/1.1 Accept: */* Referer: http://localhost.:4164/webservice1.asmx?op=Test Accept-Language: en-us User-Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0; .NET CLR 1.1.4322; .NET CLR 2.0.50727; .NET CLR 3.0.04506.30; .NET CLR 3.0.04506.648; .NET CLR 3.5.21022; .NET CLR 3.0.4506.2152; .NET CLR 3.5.30729; InfoPath.2; MS-RTC LM 8) Content-Type: application/x-www-form-urlencoded Accept-Encoding: gzip, deflate Host: localhost.:4164 Content-Length: 0 Connection: Keep-Alive Pragma: no-cache Fiddler2 Response: HTTP/1.1 200 OK Server: ASP.NET Development Server/9.0.0.0 Date: Thu, 21 Jan 2010 14:21:50 GMT X-AspNet-Version: 2.0.50727 Cache-Control: private, max-age=0 Content-Type: text/xml; charset=utf-8 Content-Length: 96 Connection: Close <?xml version="1.0" encoding="utf-8"?> <string xmlns="http://tempuri.org/">Hello World</string> Storm Request (body only): <?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <Test xmlns="http://tempuri.org/" /> </soap:Body> </soap:Envelope> Storm Response: Status Code: 200 Content Length : 339 Content Type: text/xml; charset=utf-8 Server: ASP.NET Development Server/9.0.0.0 Status Description: OK <?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <soap:Body> <TestResponse xmlns="http://tempuri.org/"> <TestResult>Hello World</TestResult> </TestResponse> </soap:Body> </soap:Envelope> Thanks for any help.

    Read the article

  • Another C datatypes question

    - by b-gen-jack-o-neill
    Hello. Well, I completely get the most basic datatypes of C, like short, int, long, float, to be exact, all numerical types.These types are needed to be known perform right operations with right numbers. For example to use FPU to add two float numbers. So the compiler must know what the type is. But, when it comes to characters I am little bit off. I know that basic C datatype char is there for ASCII characters coding. But what I don´t know is, why you even need another datatype for characters. Why could not you just use 1 byte integer value to store ASCII character. If you call printf, you apecify the datatype in the call, so you could say to printf that the integer represents ASCII character. I dont know how cout resolves datatype, but I guess you could just specify it somehow. Another thing is, when you want to use Unicode, you must use datatype wchar. But, what if I would like to use some another, for example ISO, or Windows coding instead of UTF? Becouse wchar codes characters as UTF-16 or UTF-32 (I read its compiler specific). And, what if I would want to use for example some imaginary new 8 byte text coding? What datatype should I use for it? I am actually pretty confused of this, becouse I always expected that if I want to use UTF-32 instead of ASCII, I just tell compiler "get UTF-32 value of the character I typed and save it into 4 char field." I thought that text coding is to be dealt with by the end, print function for example. That I just need to specify the coding for the compiler to use, since Windows doesent use ASCII in win32 apps, I guess C compiler must convert the char I typed to ASCII from whatever the type is that windows sends to the C editor. And the last thing is, what if I want to use for example 25 Byte integer for some high math operations? C has no specify-yourself datatype. Yes, I know that this would be difficult since all the math operations would need to be changed, becouse CPU can not add 25 Bytes numbers together. But is there a way to do it? Or is there some math library for it? What if I want to compute Pi to 1000000000000000 digits? :) I know my question is pretty long, but I just wanted to explain my thoughts the best I can in English, since its not my native language it is difficult. And I believe there is simple answer to my question(s), something I missed that explains everything. I read lot about text coding, C tutorials, but nothing about his. Thank you for your time.

    Read the article

  • XSL transformation and special XML entities escaping

    - by Tomas R
    I have an XML file which is transformed with XSL. Some elements have to be changed, some have to be left as is - specifically, text with entities &quot;, &amp;, &apos;, &lt;, &gt; should be left as is, and in my case &quot; and &apos; are changed to " and ' accordingly. Test XML: <?xml version="1.0" encoding="UTF-8" ?> <root> <element> &quot; &amp; &apos; &lt; &gt; </element> </root> transformation file: <?xml version="1.0" encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> <xsl:output method="xml" encoding="UTF-8" omit-xml-declaration="no" indent="no" /> <xsl:template match="element"> <xsl:copy> <xsl:value-of disable-output-escaping="no" select="." /> </xsl:copy> </xsl:template> </xsl:stylesheet> result: <?xml version="1.0" encoding="UTF-8"?> <element> " &amp; ' &lt; &gt; </element> desired result: <?xml version="1.0" encoding="UTF-8"?> <element> &quot; &amp; &apos; &lt; &gt; </element> I have 2 questions: why does some of those entities are transformed and other not? how can I get a desired result?

    Read the article

  • Eclipse javascript character encoding

    - by Bardock
    Hi, I'd like to display some language specific characters from javascript but I can't. My app is a Java webapp and the front end is jQuery. All the characters that are sended from the server - in a JSP or with AJAX - are displayed properly. When I want to display some text hardcoded in to the javascript file it's broken. I'm using Eclipse. In the JSP's header I use: <%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> I've tried this (charset in the script element) too: <script type="text/javascript" charset="utf-8"><c:import url="/JS/mainJS.js" /></script> In my Eclipse I've set the project properties / text file encoding to UTF-8 AND I've checked the JS files' resource properties / text file encoding that is UTF-8 too. But when I try this: $.test = function(){ var s = "éééáááuuuu"; alert(s); } I get: éééáááűűűű The strange thing is that: When I try in a separate html file (in the same project), It's working: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <head> <title>Test</title> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js"></script> <style type="text/css"> body {background: #c0c0c0;} </style> <script type="text/javascript"> $(document).ready(function(){ var s = "éááuuúúú"; $("#console").text(s); alert(s); }) </script> </head> <body> <div id="console"></div> </body> </html> Even if I DO NOT use any content type and page encoding settings. What is the problem? What shall I do? (I'm using Apache Tomcat integrated in Eclipse) Thanks in advance!

    Read the article

  • Ubuntu 10.04 and fedora 14 grub conflict

    - by sawren
    I tried to triple boot Windows xp, Fedora 14 and Ubuntu 10.04. I first installed Windows xp, then fedora followed by Ubuntu. The problem is that i don't get option to boot Ubuntu while Xp boots fine. It seems Ubuntu was unable to replace Fedora's grub with its own at MBR. Looking at their grub conf file, Fedora and Ubuntu identifies same harddisk as two different devices and i do have another 80 GB harddisk which doesn't have any OS. Below is the details on my partitions and partial information from grub files of both OS. Device Boot Start End Blocks Id System /dev/sda1 * 63 40965749 20482843+ 7 HPFS/NTFS /dev/sda2 102414436 312576704 105081134+ f W95 Ext'd (LBA) /dev/sda3 40965750 102414374 30724312+ 83 Linux - /Home (for fedora) /dev/sda5 102414438 204812684 51199123+ 7 HPFS/NTFS /dev/sda6 204812748 253634219 24410736 83 Linux -- ubuntu /dev/sda7 253634283 302455754 24410736 83 Linux -- fedora /dev/sda8 302455818 312576704 5060443+ 82 Linux swap / Solaris grub.cfg from ubuntu ### BEGIN /etc/grub.d/10_linux ### menuentry 'Ubuntu, with Linux 2.6.32-21-generic' --class ubuntu --class gnu-linux --class gnu --class os { recordfail insmod ext2 set root='(hd1,7)' search --no-floppy --fs-uuid --set cd55e078-a2c1-4d8a-9e87-ae838b6f4a05 linux /boot/vmlinuz-2.6.32-21-generic root=UUID=cd55e078-a2c1-4d8a-9e87-ae838b6f4a05 ro quiet splash initrd /boot/initrd.img-2.6.32-21-generic } menuentry 'Ubuntu, with Linux 2.6.32-21-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os { recordfail insmod ext2 set root='(hd1,7)' search --no-floppy --fs-uuid --set cd55e078-a2c1-4d8a-9e87-ae838b6f4a05 echo 'Loading Linux 2.6.32-21-generic ...' linux /boot/vmlinuz-2.6.32-21-generic root=UUID=cd55e078-a2c1-4d8a-9e87-ae838b6f4a05 ro single echo 'Loading initial ramdisk ...' initrd /boot/initrd.img-2.6.32-21-generic } ### END /etc/grub.d/10_linux ### ### BEGIN /etc/grub.d/20_memtest86+ ### menuentry "Memory test (memtest86+)" { insmod ext2 set root='(hd1,7)' search --no-floppy --fs-uuid --set cd55e078-a2c1-4d8a-9e87-ae838b6f4a05 linux16 /boot/memtest86+.bin } menuentry "Memory test (memtest86+, serial console 115200)" { insmod ext2 set root='(hd1,7)' search --no-floppy --fs-uuid --set cd55e078-a2c1-4d8a-9e87-ae838b6f4a05 linux16 /boot/memtest86+.bin console=ttyS0,115200n8 } ### END /etc/grub.d/20_memtest86+ ### ### BEGIN /etc/grub.d/30_os-prober ### menuentry "Microsoft Windows XP Professional (on /dev/sdb1)" { insmod ntfs set root='(hd1,1)' search --no-floppy --fs-uuid --set cad48cc6d48cb5eb drivemap -s (hd0) ${root} chainloader +1 } menuentry "Fedora (2.6.35.14-96.fc14.i686) (on /dev/sdb6)" { insmod ext2 set root='(hd1,6)' search --no-floppy --fs-uuid --set 6aee34cf-f77a-489a-9361-85d07194b84b linux /boot/vmlinuz-2.6.35.14-96.fc14.i686 ro root=UUID=6aee34cf-f77a-489a-9361-85d07194b84b rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc KEYTABLE=us rhgb quiet initrd /boot/initramfs-2.6.35.14-96.fc14.i686.img } menuentry "Fedora (2.6.35.6-45.fc14.i686) (on /dev/sdb6)" { insmod ext2 set root='(hd1,6)' search --no-floppy --fs-uuid --set 6aee34cf-f77a-489a-9361-85d07194b84b linux /boot/vmlinuz-2.6.35.6-45.fc14.i686 ro root=UUID=6aee34cf-f77a-489a-9361-85d07194b84b rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc KEYTABLE=us rhgb quiet initrd /boot/initramfs-2.6.35.6-45.fc14.i686.img } ### END /etc/grub.d/30_os-prober ### grub.conf from fedora default=0 timeout=5 splashimage=(hd0,5)/boot/grub/splash.xpm.gz hiddenmenu title Fedora (2.6.35.14-96.fc14.i686) root (hd0,5) kernel /boot/vmlinuz-2.6.35.14-96.fc14.i686 ro root=UUID=6aee34cf-f77a-489a-9361-85d07194b84b rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc KEYTABLE=us rhgb quiet initrd /boot/initramfs-2.6.35.14-96.fc14.i686.img title Fedora (2.6.35.6-45.fc14.i686) root (hd0,5) kernel /boot/vmlinuz-2.6.35.6-45.fc14.i686 ro root=UUID=6aee34cf-f77a-489a-9361-85d07194b84b rd_NO_LUKS rd_NO_LVM rd_NO_MD rd_NO_DM LANG=en_US.UTF-8 SYSFONT=latarcyrheb-sun16 KEYBOARDTYPE=pc KEYTABLE=us rhgb quiet initrd /boot/initramfs-2.6.35.6-45.fc14.i686.img title Other rootnoverify (hd0,0) chainloader +1

    Read the article

  • Java (JSP): repeating the contentType header in a "sub-jsp"

    - by Webinator
    What happens when headers are repeated in a .jsp you include in another .jsp? For example if example.jsp starts with this: <?xml version="1.0" encoding="UTF-8"?> <jsp:root version="2.0" xmlns:jsp="http://java.sun.com/JSP/Page"> <jsp:directive.page contentType="text/html; charset=UTF-8" /> <div class="content"> <jsp:include page="support-header.jsp"/> ... (it includes support-header.jsp) And then support-header.jsp starts also with this: <?xml version="1.0" encoding="UTF-8"?> <jsp:root version="2.0" xmlns:jsp="http://java.sun.com/JSP/Page"> <jsp:directive.page contentType="text/html; charset=UTF-8" /> ... Is that a problem? Is it bad practice? What does concretely happen when you repeat several times a header that only corresponds to one header in the resulting .html page?

    Read the article

  • How to do SoapClient on php

    - by Jin Yong
    I'm new in soapclient, I have tried to do some study online and also tried coding on soap, but seem this is still not working to me, just wandering anyone here can point out and perhaps give me some example how can I actually use the soapclint to get the feedback from the following web server? POST /webservices/tempconvert.asmx HTTP/1.1 Host: www.w3schools.com Content-Type: text/xml; charset=utf-8 Content-Length: length SOAPAction: "http://tempuri.org/CelsiusToFahrenheit" <?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <CelsiusToFahrenheit xmlns="http://tempuri.org/"> <Celsius>string</Celsius> </CelsiusToFahrenheit> </soap:Body> </soap:Envelope> HTTP/1.1 200 OK Content-Type: text/xml; charset=utf-8 Content-Length: length <?xml version="1.0" encoding="utf-8"?> <soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"> <soap:Body> <CelsiusToFahrenheitResponse xmlns="http://tempuri.org/"> <CelsiusToFahrenheitResult>string</CelsiusToFahrenheitResult> </CelsiusToFahrenheitResponse> </soap:Body> </soap:Envelope> <?php $url = "http://www.w3schools.com/webservices/tempconvert.asmx?WSDL"; $client = new SoapClient($url); ?> What should I do for the next steps so that I can get the respond ??

    Read the article

  • rails, mysql charsets & encoding: binary

    - by Benjamin Vetter
    Hi, i've a rails app that runs using utf-8. It uses a mysql database, all tables with mysql's default charset and collation (i.e. latin1). Therefore the latin1 tables contain utf-8 data. Sure, that's not nice, but i'm not really interested in it. Everything works fine, because the connection encoding is latin1 as well and therefore mysql does not convert between charsets. Only one problem: i need a utf-8 fulltext index for one table: mysql> show create table autocompletephrases; ... AUTO_INCREMENT=310095 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci But: I don't want to convert between charsets in my rails app. Therefore I would like to know if i could just set config/database.yml production: adapter: mysql >>>> encoding: binary ... which just calls SET NAMES 'binary' when connecting to mySQL. It looks like it works for my case, because i guess it forces mysql to -not- convert between charsets (mySQL docs). Does anyone knows about problems about doing this? Any side-effects? Or do you have any other suggestions? But i'd like to avoid converting my whole database to utf-8. Many Thanks! Benjamin

    Read the article

  • Unicode strings in my C# App are shown with question marks

    - by mrbamboo
    Hi, I have a header file in C++/CLR project, which contains some strings in different languages. arabic, english, german, chinese, french, japanese etc... I have a second project written in C#. Here I access the strings stored in the header file of the C++/CLR project. The encoding of the header file is Unicode - Codepage 1200 or UTF-8. the visual studio editor is able to display the strings correctly. At runtime I access these strings and assign them into a local String variable. Here I recognized that many strings are not shown correctly. Doesn't matter if I assign them or not. Accessing the original place (while debugging) shows me all the foreign strings with question marks. Especially chinese, just question marks. Example : "So?e St?ange ?ext in Ch?n?se" (This is not the best example, I know) What is the problem? I read that C# is by default UTF-16, My header file containing the strings is UTF-16 or UTF-8. I must be able to handle strings in different languages. What am I doing wrong?

    Read the article

  • Filtering Wikipedia's XML dump: error on some accents

    - by streetpc
    I'm trying to index Wikpedia dumps. My SAX parser make Article objects for the XML with only the fields I care about, then send it to my ArticleSink, which produces Lucene Documents. I want to filter special/meta pages like those prefixed with Category: or Wikipedia:, so I made an array of those prefixes and test the title of each page against this array in my ArticleSink, using article.getTitle.startsWith(prefix). In English, everything works fine, I get a Lucene index with all the pages except for the matching prefixes. In French, the prefixes with no accent also work (i.e. filter the corresponding pages), some of the accented prefixes don't work at all (like Catégorie:), and some work most of the time but fail on some pages (like Wikipédia:) but I cannot see any difference between the corresponding lines (in less). I can't really inspect all the differences in the file because of its size (5 GB), but it looks like a correct UTF-8 XML. If I take a portion of the file using grep or head, the accents are correct (even on the incriminated pages, the <title>Catégorie:something</title> is correctly displayed by grep). On the other hand, when I rectreate a wiki XML by tail/head-cutting the original file, the same page (here Catégorie:Rock par ville) gets filtered in the small file, not in the original… Any idea ? Alternatives I tried: Getting the file (commented lines were tried wihtout success): FileInputStream fis = new FileInputStream(new File(xmlFileName)); //ReaderInputStream ris = ReaderInputStream.forceEncodingInputStream(fis, "UTF-8" ); //(custom function opening the stream, reading it as UFT-8 into a Reader and returning another byte stream) //InputSource is = new InputSource( fis ); is.setEncoding("UTF-8"); parser.parse(fis, handler); Filtered prefixes: ignoredPrefix = new String[] {"Catégorie:", "Modèle:", "Wikipédia:", "Cat\uFFFDgorie:", "Mod\uFFFDle:", "Wikip\uFFFDdia:", //invalid char "Catégorie:", "Modèle:", "Wikipédia:", // UTF-8 as ISO-8859-1 "Image:", "Portail:", "Fichier:", "Aide:", "Projet:"}; // those last always work

    Read the article

  • Writing XML in different character encodings with Java

    - by Roman Myers
    I am attempting to write an XML library file that can be read again into my program. The file writer code is as follows: XMLBuilder builder = new XMLBuilder(); Document doc = builder.build(bookList); DOMImplementation impl = doc.getImplementation(); DOMImplementationLS implLS = (DOMImplementationLS) impl.getFeature("LS", "3.0"); LSSerializer ser = implLS.createLSSerializer(); String out = ser.writeToString(doc); //System.out.println(out); try{ FileWriter fstream = new FileWriter(location); BufferedWriter outwrite = new BufferedWriter(fstream); outwrite.write(out); outwrite.close(); }catch (Exception e){ } The above code does write an xml document. However, in the XML header, it is an attribute that the file is encoded in UTF-16. when i read in the file, i get the error: "content not allowed in prolog" this error does not occur when the encoding attribute is manually changed to UTF-8. I am trying to get the above code to write an XML document encoded in UTF-8, or successfully parse a UTF-16 file. the code for parsing in is DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance(); DocumentBuilder loader = factory.newDocumentBuilder(); Document document = loader.parse(filename); the last line returns the error.

    Read the article

< Previous Page | 20 21 22 23 24 25 26 27 28 29 30 31  | Next Page >