Posts

Is it possible to encode a video on client machine with a click of a button on the browser? -

This is a strange request from my client and they want to encode video using customer's machine instead of reducing customers. Server workload I wonder if this is possible? For example, I have this video and then I click the download button to download, which will download the video in my current format, and then download it will be encoded in the other format so that the client's media player Can be playable such as Windows Media Player and with more than 10 years as a programmer for my experience, I do not think Something like this is possible that there is at least one that is cross-browser compatible ... I was thinking that it could be actively able to do this, but I have to say that it is possible or No, there is no prior experience in activex to enable it. Thank you for your comments and ideas on this! Take a look at Sorenson Square gives you your browser Is not the access to Squeeze encoding power straight squeeze? You can still get encoded and any video u...

sql - Should I use Primary key here? -

एक उदाहरण के रूप में, मेरे पास 3 टेबल हैं: स्कूल: ID int, नाम Varchar छात्र: ID int, नाम varchar StudentInSchool: StudentID int, SchoolID int अब सवाल यह है कि मुझे एक कॉलम ID int रखना चाहिए StudentInSchool तालिका में प्राथमिक कुंजी ? यदि हां, तो क्यों? क्या यह अनुक्रमण करने में सहायक होगा? कोई भी मदद की सराहना की। व्यक्तिगत तौर पर, मैं समग्र पीके ( StudentID और SchoolID ) इस तरह तैयार करता हूं। यह विशिष्टता भी सुनिश्चित करता है। अगर, विशिष्टता की आवश्यकता नहीं है, आपको प्रत्येक पंक्ति को विशिष्ट रूप से पहचानने के लिए एक आईडी कॉलम जोड़ना होगा। आम तौर पर, एक अलग आईडी कॉलम के अलावा ज्यादा मदद नहीं मिलेगी: बहुत कम प्रश्न (यदि कोई हो) वास्तव में इस कॉलम का उपयोग करेगा। प्रदर्शन के लिए, आप प्रत्येक कॉलम के लिए अलग-अलग अनुक्रमणिका बना सकते हैं और आप बस ठीक हो जाएंगे।

python - Help me understand Inorder Traversal without using recursion -

I am able to understand the previous traversal without using the rearrangement, but I have been having a hard time with the Inner Traveler. I do not seem to get it, perhaps, because I have not been considered for the inner work of repetition. This is what I have done so far: Def traverseInorder (node): lifo = Lifo () lifo.push (node), while true: node If no one: break the node. No left, none: lifo.push (node. Left) node = node. = Node while true: if no node is: brake print node .value prev = node node = lifo.pop () node = pre node. There is no right: lifo.push (node. Right) node = node. : Break The internal timing loop just does not look right. Apart from this, some elements are being printed twice; Maybe I can check that the node has been printed first, but this requires another variable, which does not seem to be correct again. Where am I going wrong? I have not tried postorder trials, but I think it is similar and I must face the same conceptual blockage there too. T...

How to correctly free a PDO instance -

For example: $ db = new PDO; // using some code $ db here // and after that, I want to free this var and close all connections and $ db = NULL; // How correctly? Is the correct way to free all SQL results and connections? You can do this, but often not necessary if a function is created and another If the Vars is not using it, then it will release the content of $ db when it gets out of the scope (usually at the end of the function). If $ db is a global, then it will be released when the script ends.

c# - How to programatically access images in a resource file? -

I have 30 PNGs in the resource file and I want to see them again inside the timer. This timer has set the background image of the form to the next PNG of the form to create an original animation. I can not find an easy way to enumerate the resource file and get it on the actual pictures. I'm eager to keep the references to images that are not fixed on their file names, so updating the naming of images within the resource file will not require me to update the code in this section. Notes: Images are named in order of the resource file ('image001.png', 'image002.png' , ...). This resource file is used exclusively to store these images. private zeros form 1_load (object sender, event erggus e) {var list = WindowsFormsApplication1.Properties.Resources.ResourceManager.GetResourceSet (New system. Globalization.CultureInfo ("en-us"), true, true); Foreach (in system.collections.DictionaryEntry img list) {System.Diagnostics.Debug.WriteLine (img....

java ee - Running standalone Glassfish v3 client as Eclipse plugin -

I am developing a standalone client who invites some EJB methods on Glassfish v3. This works fine until I am integrating an Eclipse plugin to run the client in our RCP application. In this setting a classmaker problem appears when you start the naming context, and I get the exception listed below. (Client in client has gf-client.jar and all its dependencies.) This fails m_ctx = new InitialContext (); with exception java.lang.NoSuchMethodException: org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.findResources (java.lang.String) . Init & gt; (ManifestProxy.java:34) at com.sun.enterprise.module.single at java.lang.Class.getMethod (Class.java:1605) com.sun.enterprise.module.single.ManifestProxy & lt at. ProxyModuleDefinition. & Lt; Init & gt; (ProxyModuleDefinition.java:78) at com.sun.enterprise.module.single.ProxyModuleDefinition. & Lt; Init & gt; Com.sun.enterprise.module.single.SingleModulesRegistry (ProxyModuleDefinition.java:73). & L...

perl - How can I make $1 return alternatives without a substitution regex? -

I recently incorporated the project into the logic of code and database elements. Business logic, such as expat, regular expressions, and function names, are recorded in the database, while reading general code such as files, making xml from xpath etc. are in code base. Most (if not all) the methods that use regular expressions are structured like this: if ($ entry = ~ / $ regex /) {$ req_value = $ 1; } This means that only $ 1 is available and you must always have your RegEx written in your $ 1 to give you the desired results. Problem: The result of the following string is either '2.6.9-78.1.6.ELsmp (SMP)' or '2.6. 9-78.1.6.ELsmp should be ' based on SMP's existence. $ 1 $ entry is not enough for [0]. $ entry [0] = qq | Linux version 2.6.9-78.1.6.ELsmp (brewbuilder@hs20-bc2-2.build .redhat.com) (GCC version 3.4.6 20060404 (Red Hat 3.4.6-10)) # 1 SMP Wednesday 24 September 05 : 41: 12 ADT 2008. | $ Entry [1] = qq | Linux version 2.6.9-78.0.5...