Posts

Showing posts from September, 2015

Programming a demo of a web app in jquery -

We are deploying some small web applications. Resources, we are now looking for a casual user to speed up (with our bad design;)) now in a simple way. What are the jQuery plugins that can be used to create demos? (Fire incidents, move dialogs, etc.?) Should we use a completely different approach? I like to do mockups like something - in this way the customer does not think that this Actually in fact it is.

php - Is setting the uploads folder 777 permission secure? -

I have seen cutting out many upload forms, and in some, some uploaded files actually had a good security check. (At least I think so), but still managed to upload any single PHP file. I was thinking: Is there a way to upload files in the uploads folder that has 777 permissions? I'm thinking of using HTTP PUT. In general 777 unsafe is happening as it is ... its meaning That anyone can read and write your files If you are allowing uploading files to tamper with you then HTTP PUT is not naturally secure from any HTTP post. Overall, if you have to allow arbitrary files to execute, you have to do a very good file to check for server-side, and Croit It would be wise to use it. Permission-wise, I usually reach to some web-webserver user-owned 644.

Files for use in Feature activation of a web application scoped feature SharePoint 2007 -

Is it possible to access local system files in a feature activation event that is scanned at the web application level? Yes, I tried to initiate the process of an SP timer job indirectly, which That a temporary file was received from another webservice method. Maybe this complex timer is also possible without a job scenario, but it works perfectly with the timer job.

sql - Ordering in a MySQL GROUP_CONCAT with a function in it -

I want to order results in a GROUP_CONCAT function. The problem is that selection in group_concat -function is another function, such as (fictional selection): SELECT a.name, GROUP_CONCAT (DISTINCT CONCAT_WS (':', b.id, CNID) order by B.ID ASC. People A, luggage B, course C. Group a.id I want to get a result .ID): Michael 1: Science, 2: Mathematics, 3: Physical Science But I'm getting: Michael 2: Mathematics, 1: Science, 3: Physics What I Isi can order here in group_concat by anyone know how I b.id? If someone cares, then I think I have at least one problem Has found a solution. Select 'GROUP_CONCAT' (from the order table of the column name with some columns) '|') where fieldId = p.id P> This sequence goes according to the group - if there is one then before the separator

Writing to std out from Java JNI DLL - output only appear when application exits -

We are writing JNI DLL to wrap a third party DLL. In our DLL, we are writing debug statement in standard out. When we use DLL from our Java application, there is no impression on the Java console during application execution. When the application stops, all outputs from DLL are written on the Java console. We want to output from DLL, so the application appears on Java console, as the application is implemented Does anyone know why this is happening, and What can be done to get the product during the application execution? Try flushing output. If that does not work, then pass System.out in your DLL and use PrintStream instead of stdout . but Fflush (stdout); must be enough.

c# - UserControl with Child Controls passed into a Repeater within the UserControl -

I'm trying to achieve something with lines of UserControl (MyRepeater ) & lt; P & gt; Start control & lt; / P & gt; & Lt; Asp: Repeater id = "myrepeater" runat = "server" /> & Lt; P & gt; Control end & lt; / P & gt; page & lt; P & gt; Start page & lt; / P & gt; & Lt; Uc1: MyEperPeter ID = "MyRepter 1" Runat = "Server" & gt; & Lt; ItemTemplate & gt; & Lt; P & gt; Page item template & lt; / P & gt; & Lt; / ItemTemplate & gt; & Lt; / UC1: MyRepeater & gt; & Lt; P & gt; Page end & lt; / P & gt; The item from the page object will be used as a replayer's item template within the template. The reason for this is that we use many repeaters, our applications, each repeater and some related buttons do the same code. I would like to keep this code in one place so that developers can use our custom repeater contro...

Drupal Imagecache not working -

I created an image setting that comes in only 125px wide size The first issue is that the preview image is 404. Then I & lt ;? I want to print an image through the Php print theme ('imagecache', 'imported_image'). , $ Node-> Picture, 'test', 'test', $ attributes); ? & Gt; 'imported_image' preset and $ node-> the picture is a correct path I HTML prints right out, but the path that the image is trying to load does not exist is. There is no folder with the preset name in the sites / default / file / image cache; The predefined flushing does nothing; The Imagecache folder is writeable by everyone, it is on the mmp. Does anyone know what this problem can be? Imagecatch Friendly URLs are closed when not working If this is the case, then the site / default / Find the path to your folder in the files 'no'. When I turned them on, the folder was created properly with the name. Imagecached images do not appear here. ...

.net - ADO vs DataSet and DataTables -

So I did not see the answer to my question: Is there any difference (display or otherwise) ado Vs dataset? If so, which is more common? The ADO is the way to actually get the data. I think you are mixing things. The dataset is basically a memory representation of the data you have drawn and it is OK to set a small result, but edit: its Apart from this, for the big result set, generator list populates through the detrars, as far as the performance goes. For an example of a dataset, I had to re-write a report that was taking more than 9 hours to run. It was a console application that was generating CSV, the programmer filled 1.4 million records in a dataset, then used for each loop through each line. It took not only 10 hours, but during the walk, it was recalled 4 Gigabits. After deleting the dataset, the report now runs within 5 minutes and takes approximately 20 MHz of memory. Just one example.

flex - IOErrorEvent Eluding Capture -

I am working on a Flex application that processes and displays HTML in small amounts, sometimes with images Sometimes I'm receiving HTML outside of third-party RSS feeds, I see it in a pop-up window: Error # 2044: Unrestricted IOErrorEvent:. Text = error # 2035: URL not found. The RSS URL is just fine, but apparently there is something in HTML which is causing a problem. Since the application is to run as part of a non-interactive digital science, therefore whichever one click is required to continue, it is totally unacceptable. I do not care how bad or bad the URL is. ; The app must ignore the problem without disturbing the user. Unfortunately, I do not have any luck to trap this incident. I am generously sprinkling the calls via code like this: [item] .addEventListener (IOErrorEvent.IO_ERROR, handleIOError); ... Where [Object] is everything from MX: Render the text object to HDM in its MX: Canvas parents MX: The application top-laser app, and handleIOError is ...

c# - Dont want textbox to enter null value in datatable -

I have a data table that already has some values, as well as receiving values ​​from a text box below. Now my problem is that when I do not enter a value in the text box that still enters the data table. I do not want to do this .. The code can run on any machine ... any suggestions ???? thanks public partial class WebForm6: System.Web.UI.Page {DataTable dt; Protected Zero Page_Load (Object Sender, EventArgs E) {// Start a DataTable if (! Page.IsPostBack) {dt = New DataTable (); // Start DataColumn DataColumn myDataColumn = New DataColumn (); Start //// to add a new instance to a different column in the initial form of DataColumn with different properties. // myDataColumn = New DataColumn (); MyDataColumn.ColumnName = "firstName"; // Column's datatype property as string myDataColumn.DataType = System.Type.GetType ("System.String"); // Add and create another data column dt.Column.Add (myDataColumn); // Create a new row using the DataTable's NewRo...

sharepoint - 2 accounts reference 2 different master pages? -

This is bothering me for a while. I am developing a SharePoint MOSS 2007 site, I have a set of accounts There is no problem with accessing the site and using the right master page. When I use the second group of Windows user accounts, they use a completely different master page for me unknown, there is no logical separation between those groups, which means that 1 account is correct from 1 department Can behave in a manner and the second account is in the form of the same department, which should have the same privilege, references a different master page. When I see the program, what is the master page, it displays standard default paths similar to "_catalogs / masterpage / default.master" for other users. The strange thing is that it seems that this separate master page is actually the same, but its old version is anyone who has experienced this issue? How do I fix this? Have you checked the master pager after checking it and Is the new version available for ...

php - How to make ImageMagick Imagick class available? -

This is really an amateur question, but I have established my ports on FreeBSD. However, when I use $ image = new Imagick ($ filename); I am getting: Fatal error: Class 'imagic' is not found in /usr/local/www/test.php on line 1 How can I access this class for a script? Pickle installed imagery

sql - Ensuring result order when joining, without using an order_by -

I have a mysql plugin that will return the results set in a specified order. Part of the result set includes a foreign key, and I want to join that key, while ensuring that the order remains the same. If I do something like this: SID = F.Id's internal join of the sphends F. F. F, choose Fitil, where query = 'test; Filter = type, 2; Sort = atriosak: static '; It seems that I am getting my results back so that Sphinx gives them returns. Is this a quote from mysql, or has I been assured that no involved order will change? If you need a guaranteed command in the result of a query, use ORDER BY Do some more willpower thinking. To give some information on this, several database execution steps are split in a way that can vary depending on the execution of the query, the available CPU volume, and optimization Just like the database can be estimated. If a query runs in parallel on many threads, the results may vary. If the plan changes, the results may vary if ...

sql - How do I list all the columns in a table? -

For different popular database systems, how do you list all the columns in the table? For MySQL / Oracle, use: DESCRIBE name_of_table ;

How to mix C++ and external buttons on seperate window? -

I have to create a C ++ button on Start> Run, but when I do What do I get to indicate? I'm sorry I have seen that you do not get the question. OK when you CreateWindowEx () ; I want to do this but put a separate window with SetAprent which I have already done Now the button is not working, so I need my program when it runs from the run window Clicked for example! And yes you have it but this button is not making the problem, the problem is when it has been clicked with my program because it is no longer! Older but still supported in Windows as you subclassing The technology needs to be implemented; It has been well explained (15 years old article, but still quite legitimate ;-) As it is written in this article, Sub-closing is a technique that is a Allows the application to block messages for the second window. Touching the message messages for another window can increase, monet, or modify the default behavior of a window. You would like "insulati...

When to use Dependency Injection -

I feel certain that dependency-injection really can not be "I can not really say my "I know it may seem silly, but in fact it is about the argument that why should I use dependency injection (DI)?" It is often said that I should use DI to achieve high level of loose coupling, and I get that part. But in reality ... how often do I change my database, when my choice falls on MS SQL or MySQL .. Very few right? Does anyone have some very attractive reasons because this is the way Two words, unit tests . One of the most attractive reasons for D is that it is easy to allow unit testing to hit one unit and not to worry about setting up 'test' data.

Is this a right way to put Java generics in action? -

I have started messing with the generic and I have to ensure that I got this right, any help? Public Interface Cart & lt; Tee CartItem & gt; {Public Zero Settings (List & lt; T & gt; Items); Public listing & lt; T & gt; GetItems (); } Public Interaction CartItem {Public BigDecimal getQty (); Public zeros set (Bigdishci kwati); // more} public category cart service & lt; T, cart & lt; E & gt ;, E increases CartItem & gt; {Public Zero addOrReplaceItem (T-cart, e newCartItem) {List & lt; E & gt; Item = cart.get items (); Int Status = Items Index (newcartime); If (status> gt; -1) {e present item = items.jet (status); CurrentItem.setQty (existing ITem.getQty) .add (newCartItem.getQty ())); } And {items.add (newCartItem); }}} Public interface grocery cart extension cart and lt; GroceryCartItemImpl & gt; {// more} Public interface grocery cart eTam spreads {// more} Public category grocery rent ITemImpl applies Serializable, Grocer...

Displaying custom cursor in the full screen mode - Flex 3.0 -

I am having trouble displaying a custom cursor in the full screen mode of my Flex application. How can I do this? cursor manager. The reverse cursor () deletes a cursor from the cursor list. If the cursor has been removed, the currently displayed cursor, the cursor indicates the next cursor in the manager list, if any exists. If the list is empty, the cursor manager displays the default system cursor. I can not find a way to add a deleted cursor to the caller list again in addition to calling setcursor . The following code works side-by-side with full screen mode. custom ID grows in each call - but atleast it works fine. & lt; Mx: application xmlns: mx = "http://www.adobe.com/2006/mxml" layout = "vertical" xmlns: local = "*" & gt; & Lt; Mx: button label = "custom" click = "onCustomClick ();" /> & Lt; Mx: button label = "default" click = "onDefaultClick ();" /> & Lt; Mx...

xml - Document specification in markup language? -

I'm not sure that before the hand it pardons it: what a markup language to create document specifications specifically is? For example, if a given document requires people to provide them with template word documents, then they have to include the what document and how It should be structured. I am thinking that this could be possible using XML, but I want to know that something is clever: thanks Edit: Thanks for the answer. I think the above example is called with the best example. In order to issue data to a third party in my organization, they will have to fill out a security policy that contains some information on how to ensure that the data is kept secure at their end. In most cases, people will download word templates for it. Fill it and send it back. I want to make a formal specification that what should be included in a markup language in that document It is possible that people have probably created tools or other things about document creation. I real...

swing - how to stop cell editing in JTextPane ,cell editor of JTable -

I created JTablePane as a cell editor. I want to stop editing the cell and if I enter the key in JTextPane And I also want to use a line in JTextPane. Therefore, I add main list creator to JetExpain and call Stopclitting method. But this is not working, the focus is in jettextpen and if I click on the other cell, then the selected row and the selected column do not change. So, please help me use a line in JTextPane and if I join the default cell editor. thanks a lot! Hi, I have just come to the same problem, I have a custom editor and default fire edit It was resolved by signing on Extending Private CelEditor AbstractCellEditor implements TableCellEditor {/ * here other code for editor ** / protected void fireEditingCanceled () {this.stopCellEditing ( ); }} took me a while to understand it, except if it does not work, you can use the model.setObject (object, line, call) in the cancel function Can try.

flex - SQLite gurus: how can I display very detailed metadata about a file? -

I have a situation where a simple query against the table is returning an incorrect value in Flex, but other GUI front-end Choose the title from TTL where ttl.ttl = 140 // ttl is also the column name of PK column is returning the title Is related to a row whose pk = 1400 . ttl.ttl is defined as int datatype. Again, the problem itself appears only > How can I ask internally to help solve the problem? I'm definitely not a guru, but hopefully some useful information can be provided. a. Sqlite command line tool If you are running the sqlite3 command line access program, you can type ".tables" to get a list of all the tables. Or you can type ".schema" to see the entire database schema, including all tables and indices. B. By code SELECT name sqlite_master WHERE type = 'table' by name ORDER; View. Edit: After reading your post on the Adobe Forum, I think your problem is here: Ttlid should be declared as inte...

html - <table> vs <div> (yet again) -

I generally agree with the idea that the layout of the web site is & lt; Table & gt; Instead of & lt; Div & gt; Should be done with. However, I have a situation where it does not work - or at least, I have not found any solution. I have a dynamic site where many customers share the same template (they can choose from one set of available templates) defines the general layout of a template site - usually the top, Two or three columns (menu at the top, primary content in the middle, and sometimes additional material on the right), and the footer at the bottom header - nothing fancy. Customers' header and content on the right side and the control of the menu and key content areas have complete control over important controls. The point here is that I do not know what the width is, of any column. Customers can have long or short text for each menu item, they can put small or large images in the right-hand column, and the main content can be a free-to-none. I can...

jquery - Calculating text width -

I am trying to calculate text width using jQuery. I'm not sure what that is, but I'm definitely doing something wrong. So, here's the code: var c = $ ('. Calltoaction'); Var cTxt = c.text (); Var cWidth = cTxt.outerWidth (); C.css ('width', cWidth); This works better for me: $ .fn.textWidth = function () {var html_org = $ (this) .html (); Var html_calc = '& lt; Span & gt; ' + Html_org + '& lt; / Span & gt; '; $ (This) .html (html_calc); Var width = $ (this). Find ('span: first'). Width (); $ (This) .html (html_org); Return width; };

iPhone UITextView leaves room for 2 lines at the bottom -

When I start typing in a default text view in my view controller, do not go below this text field Used to be. It leaves space for two lines of text and then starts scrolling. I want to start scrolling when I start moving ahead from the last line. I tried to do everything, and I do not know what can I do? UITQviewView is a subclass of UIScrollView, looking at the properties of UIScrollVIE, any ideas like content insert and others? to see if they are making a difference between your frame / boundary and the content .

How can I fade out, change test and then fade in with jQuery cleanly? -

I'm playing with a div that I have a change on a user action, I want to dim it, node I want to change the price and then faid. Whatever I try, I always look at the value change because the element is fading. Can anyone help? calculator_result.fadeOut (); Calculator_result.css ("color", "#fff") Html ("& amp; Euro;" + vRelief + ".00"); Calculator_result.fadeIn (); This is the code that I am using now but I tried to do it in a different way! A delay can work but definitely the way of these cleaners? Cheers, Dennis Changes in callback for fade and fade when you If you do this in the callback, the code will not run until the effect is complete. calculator_result.fadeOut ('normal', function) ($ {this} .css ("color", "#ff"). Html ("& amp; euro;" + vRelief + ".00"). FadeIn ();});

coding style - HTML toggle buttons -

I need to represent a toggle button in HTML. I intend to do a normal input with submit button and style . How is it that how to style a toggle button and more or less work in all browsers? Since you are representing a control with a true / false situation, then you actually Downlive Browsers want to use a checkbox as the built-in form element to maintain compatibility with the screen reader and so on. Here is a label control affiliate with an approach checkbox, and then to use the combination of CSS and JQ to create the 'real' checkbox 'invisible', presenting the label as a button, and labeling the property to the property Modify because checkboxes are checked or unchecked. This code works in Chrome, Safari, Opera, Firefox and IE (IE is due to conditional comment hack because IE treats hidden form elements differently for other browsers). If you submit the attached form, you get the normal HTML checkbox behavior as a result. & lt ;! DOCTYPE html public...

ruby - Forking a gem for a Rails project -

I have found myself twice in this situation: I install a gem on my system and it is my rail project I start experimenting with After all I have to make some changes in that gem. How should I proceed? Ideally I would like to check the source code of that gem, like ~ / third_party / gem, work on it and use my rail projects instead, is it possible? In all cases the jewels were in Github, so I would probably clone it in Gitanbu, keep my spot and maintain my branch. I think I would set that branch straight by installing a gem on my server. Does this make sense? Today it is very easy to do this with the bundler, you make a local copy of the gem and then your own jamphile Instead of doing gem "whatever you do" you do: gem "whatever" ,: Path = & gt; "/ Home / pupeno / whatever" After installing the bundle, Mane has been selected from that directory. Even if you modify something there, you need to reload, this is to restart the rail. ...

c++ - What is the simplest way to execute arbitrary process with stdin, stdout forwarded to a socket? -

I am interested in two situations: How to do this from C ++? How to do it from the system shell The answer is welcome for Linux, Windows and OSX. Linux / OSX (actually posix), programming (in any language that has posix calls) General plan: Setup a socket .. Fork () Close (0) , Close (1) ( No dup2 (socket, 0) , dup2 (socket), dup2 1) exec () shell: use nc . Example in my other answer:

SQL Server 2008 - Table - Clarifications -

I am new to SQL Server 2008 database development Here I have a master table called 'Student' And there is a child table called 'Address'. The common pillar between these tables is 'student id'. My suspicion is: Do we make 'address' table and primary key? Is it mandatory? (I will not use this 'Address ID' in any of my reports) Should the primary key column be in any table? Will you help me on these? Would you please see the best link / tutorial for SQL Server 2008 database design practices (if you know) that includes naming conventions, best practices, SQL optimization, etc. 1) Yes, ADDRESS_ID column to ADDRESS Table is a good idea. But STUDENT_ID is not a good idea as a foreign key in the ADDRESS table. This means that an address record can only be linked to one student. Students can be living in the room, so they will have the same address. Which is a good idea to have the ADDRESS_ID column as a priority, bec...

PHP and MySql hitcounter problem? -

OK I am new to php and mysql, I tried to make a web page hit counter but update my page counter Did not happen correctly and the following warnings are listed below. WARNING: mysqli_query () WARNING: At least 2 parameters given in mysqli_num_rows (), 1 is expected to be 1 mysqli_result, boolean Here is the php code. & lt ;? Php $ page = $ _SERVER ['SCRIPT_FILENAME']; // Query member data from database and ready to display $ mysqli = new mysqli ("localhost", "root", "", "sitename"); $ Dbc = mysqli_query ($ mysqli, "mysql_counter_logs SELECT id page where page = '$ page'"); If (mysqli_num_rows ($ dbc) == 0) {$ mysqli = new mysqli ("localhost", "root", "", "sitename"); Include $ Dbc = mysqli_query ($ mysqli, "mysql_counter_logs (page) values ​​('$ page')"); Mysqli_query ($ DBC); } Otherwise (mysqli_num_rows ($ dbc) == 1) {$ mysqli = new mysqli (...

C#: Archiving a File into Parts of 100MB -

In my application, the user selects a large file (> 100 MB) on his drive I wish to program How do I choose the file that was selected and Cut it into stored parts which is 100 MB or less? Should I use libraries and file format ? Can you give me some sample code? After becoming the first 100 MB stored part, I am going to upload it to a server, then I will upload the next 100 MB, and until the upload is over. After that, I will download all these archive parts from any other computer, and then I want to add them to the original file . What is possible with 7zip libraries, for example? Thanks! Update: By the first answer, I think I'm going to use Sevenzipsharp, and I believe that now I understand that a file is stored in 100MB How to divide into parts, but I still have two questions: Is it possible to make the first 100 MB stored part and upload it before creating the next 100 MB part? How can you remove a file from many split archives? UPDATE # 2: I was just...

internet explorer 7 - IE Conditionals suddenly stopped working after Windows XP Security update -

There is really strange stuff going on here. I have installed some security updates for XP ... Then I set my text editor to do some coding, and I understand that my IE terms do not work anymore. Anyone have any suggestions for me? I have made a mistake that the cows come home to mole I have tried to uninstall updates, but Windows has restored them. Do you have a standalone version of IE 6, 7 and / or 8 with the original version? The original version is the version which works with conditional comments. For example, if you have IE8 installed via software update, standalone IE 7 and IE6 will only execute anything within IE 8 conditional comments.

c# - How to Write Proxy Methods? -

First of all, I do not know the correct way to describe the word "proxy methods" but let me know I actually I want to know: Suppose I have a classic called Proxy Class, which has proxy methods class ProxyMethods {Public Zero CallHillowWord (); } In fact it is a mirror, the actual code is storing in a web server. So how would this be the real way to find out in a web server without using it in the web server? In this way, my own code will be safe, if there is a refactoring software Reactors DLL located in the client's computer, then only it will show that the basic method is signature and some connection data that is located in the real server Is used to connect. How do I complete it? Maybe remoting? I'm not sure why you are trying to avoid web services? Regardless, WCF is the way to go these days Remoting is almost completely obsolete, with WCF, if you wish, there is a configuration change to go from traditional soap on HTTP web service transpor...

Improve Concentration/Workspace? -

How can you find yourself in the "zone" for programming? As a CS undergraduate I found it difficult to focus. I think part of my problem is that I do not have "proper" workstation in dorms. Any thoughts or suggestions? (Probably good thinking music, whiteboard etc.) In the best way I've found the internet so far It has become almost a reversal to open my browser and browse to some random site, so whenever I need to work, I disable my network card. In this way I have time to find out that before it is too late. Internet number should be "Zone Killer" I know ...

Using a secure web service from iPhone with SOAP -

I am trying to get secure web service connectivity via https on SOAP via https. Currently working with NSMutableURLRequest in http, but it does not support https What is it that I am after using the safe web service to use any idea and processing? Any help appreciated // :) use GSOP It's a C / C ++ library that provides fast and secure access to web services; You can also develop your own, though it basically does not support the purpose C, it is still IMHO is the best open source web services library Additional information and downloads can be found

security - Is the password weak under dictionary attack -

Thanks for watching All honestly answered useful answers are I used the password password meter So that the user will know how strong the password they choose is. But the password tester does not clearly tell how much I am weak under a dictionary attack during the password, how do I check for it, and is it worth it? In addition my regular password checker starts with Javascript in the browser (no broadcast is required). If I want to check for the weakness of the dictionary attack, then I have to broadcast it on a script. I understand that I should not broadcast it clearly. Can someone help me? How do I password under a dictionary attack is not weak and how can I encrypt it before transmitting to my script? Additional information: Why do I feel that I need to check dictionary attacks other than regular password meters? As some of you have said, users can choose a password like P @ SSword or Yellow12. But most password strength checkers coming to me will be considered as ...

algorithm - Understanding word alignment -

I understand what it means to reach the memory that it is a coalition, but I do not understand why this Necessary. For example, how can I use a byte from an address 0x ... 1 but I can not use one half word (two bytes) from the same address. Again, I understand that if you have an address of A and s , then the entry is aligned if A mod S = 0 . But I do not understand why it is important at the hardware level. The hardware is complex; This is a simple explanation. A typical modern computer may have a 32-bit data bus, which means that any fitch that needs to be done will receive a special memory address for all 32 bits . Since the data can not just fetch anything less than 32 bits, so at least two address bits are not used on the address bus, so it seems that the 32-bit words instead of 8-bit bytes . When the CPU does one fetch for a byte, then the reading cycle will bring 32 bits and then the CPU will end 24. Those bits, the remaining 8 bits which are loaded in ...

Disable specific dates in jquery -

I'm using the jquery date picker found here: which lets the user choose a start and end date. Although I want to be able to disable specific dates I tried to apply the code found here: which discusses disabling national holidays. This is my complete code: $ (function () {$ ('date-pick'). DatePicker (before {ShowDay: nationalDays}) // $ ("Selector") Datepicker ({ShowDay: nationalDays before}) [5, 25, [4, 27, 'za'] [5, 17, 'Nu'], [3, 17, 'or'], [5, 25, 9, 7, 'BR'], [10, 1, 6, 6, 'from'], [7, 4, 'we'], [8, 17, 'id'], [ 9, 7] 'CN'], [11, 22, 'LB'], [12, 12, 'K']]; For national day (function) (i (i = i; i & lt; natDays Length; i ++) {if (Date.getMonth () == natDays [i] [0] - 1 and amp; amp; date.getDate () == natDays [i] [1]) {Return [wrong, net day [i] [2] + 'day'];}} return [true, ''];} $ ('# start-date'). Bind ('DPClosed', function (E, sel...

programming languages - Why are closures suddenly useful for optimizing programs to run on multiple cores? -

I have read the claim that closing "war on multicore" (or "block") is a useful tool because [...] They allow you to make units of work, each of which has a copy of their stack, and as a result, do not move on each other's toes. What's more, you can pass these units in a rough way as they are worth, when in actual fact they have a complete stack of values ​​(different intentions) and executable code to do some operations. Now, I am not discussing the usefulness of general shutdown for concurrent programming in a shared memory memory and possibly , but what is the difference with a thread that only works on local data (or processes, or actor, or ...)? Is useful for a uniformly concurrent programming without the scheduler? What are the non-local side effects that stop it? The argument is that by completing your programming language, it is easy to do some work in the second thread. I think the author has mentioned the importance of the hig...

Online resources for premade WPF styles/control templates? -

When it comes to UI design, I usually do not care about custom style (appearance-wise), I Not much of an artist and I hate trying to come up with interesting color schemes and likes. Are there any online treasures of premade WPF styles and / or control templates? I could have sworn that I had seen one before but I can not get it now, it can be. If you guys know something like this then just curious. It would be great to be able to spruce up for a while in a premade style in your application. is here.

java.lang.OutOfMemoryError: Java heap space in jasper report -

When I export content in the doctor format, I get a Java heap space error, java.lang.OutOfMemoryError: java.util.Arrays.copyOf (unknown source) at java.io.ByteArrayOutputStream.write (unknown source) at sun.nio.cs.StreamEncoder.writeBytes unknown source (unknown source) sun. Nio at Sun.nio.cs.StreamEncoder.write (unknown source) at sun.nio.cs.StreamEncoder.write (unknown source) at java.io.OutputStreamWriter.write (unknown source) .cs.StreamEncoder.implWrite (unknown Source) at Java.io.Writer.write (unknown source) add the best -XX: + HeapDumpOnOutOfMemoryError When an outofmmy error occurs, and then analyze the example of hep dump, which will show you the amount of the object and usually identifies the objects due to the outoffemme error.

vb.net - How to work with multiple updates by linq to sql? -

First of all, I would like to ask if it is possible to edit many records by the linqtosql method in a click event? What I am trying to do is edit all the names in the table, I had the same account number I was able to edit, but only one name has been edited and there are no rest, if possible I really appreciate it if you take your time with me to resolve this issue. Give me the code you use. / P> Private sub button 2_Click (------------) button handle 2. Click the slow accnt string accnt = Textbox1.Text dim db as new memrecDataContext () dim editrecord = From Mem in db.Table1s _ where mem.Account = accnt _ editrecord mem memes in each mem.Name = Textbox2.Text db.SubmitChanges () Next MsgBox ("Successfully Completed", MsgBoxStyle.Information) End Sub Why is it that only one of these codes can be used to edit the records in Dato? Can you debug the code to edit all records, which are being queried when there is a single account number? If this is possible for you. ...

python - Custom Django-admin command issue -

In an attempt to understand how a custom admin command works, I have my project called "mailing" and the name " Msystem ". I have written it in retrieve.py mailing / msystem / management / commands / folder and I have pasted an empty init .py and both management and cpmmands folders. Import alarm command from BaseCommand mail.msystem.models from the Django.core.management.base Import Commands: Base = "data shows" DRF handle (self, * args, ** Option): X = Alarm.Obages I have all the () for x: print I.name I'm trying to "pause management / retrieve" when I get the "indention" error strange, but this I feel good for me, can you suggest me what I have to do or what is the problem me thanks Your indentation should be consistent through the entire file, which is not in the snippet you posted above. Yes "help =" line is applied after four "squares", but then the "x =" line has been indented...

php - framework questions. How can I reuse the same template? -

I hope I can get a definite answer on this. I will try and explain it as I can. I have a main template file that contains everything I want. Within a small area within this template, I want to resonate the view that is linked to the link that the user clicks on. It's not a problem anymore, but when I want to use loop data, it's not so easy anymore. If I have this as my template: Table Tr> td> & Lt ;? Php echo $ myContent; ? & Gt; & Lt; / Td / tr / table You can clearly see how I will be able to resize the values ​​of the variable. Now, suppose I want to show something to the user for which many rows of data were necessary. Then I have to use a loop, so you see, it depends on the content that I want to display determines how to construct within HTML. Can anyone help me understand this? I'm sure it's just not me properly understanding how it should be done. Thank you & lt; Div & gt; & Lt; $ Content $ & gt; & Lt...

SQL Server 2008 select top 1 row from multiple tables? -

I have a table that stores articles, for example: article table: id # class # text # date # date So on the page I have different sections and each section has its own ID. For example, the game is 1, news 2 etc. Now I want the possibility of loading the latest article from the X number of categories. So now the question is how can I choose the latest inclusive articles from categories in Natura? I used to get in the table of ID using the Arrest-to-Table of Erand Somerskog () Generally I select articles from several categories to Using something like: SELECT was published article, title, category ID, stenography, date from article where article = 3 and category IID (selection i.number From iter_intlist_to_tbl (@ categories) as i) Date published by DESC But what sort of categories do I choose from only the old article? select one. * From iter_intlist_to_tbl (@ categories) I do not have any of this by the external application (select top 1 * article where the ...

c++ - Debugging with Eclipse CDT and GDB -

मेरे पास ईक्लिप्स सीडीटी सी ++ एप्लीकेशन प्रोजेक्ट है जो साझा लाइब्रेरी का उपयोग करता है। यह लाइब्रेरी डिबग जानकारी के साथ संकलित है और उसका स्रोत सही रास्ते पर उपलब्ध है। अब मैं एक्लिप्स और जीडीबी के साथ अपने आवेदन को डिबग करने की कोशिश करता हूं। अगर मैं अपने आवेदन स्रोत कोड में ब्रेकपॉइंट डालता हूं, तो सब कुछ ठीक है। तब मैं शामिल साझा लिब की एक स्रोत फाइल को खोलता हूं और वहां ब्रेकपॉइंट डालता हूं। डीबग सत्र को लॉन्च करते समय मुझे चेतावनी दी जाती है कि "लोड किए गए प्रतीकों में xxx.cpp नाम की कोई स्रोत फाइल नहीं" और उस समय निष्पादन को रोक नहीं है। अगर मैं एक ही फाइल में एक ही ब्रेकपॉइंट डाल दिया है, जब डीबगिंग सत्र पहले से ही चल रहा है, तो सबकुछ ठीक काम करता है क्या गलत है? आपकी मदद के लिए धन्यवाद। मुझे यही समस्या थी , क्यूटी प्लगिन (जो कि विंडोज डीएलएल पर आधारित हैं) में सेट ब्रेकपॉइंट्स की कोशिश कर रहा है। मुझे यह चर्चा मिली और समाधान मेरे लिए पूरी तरह से काम किया, हालांकि मैं आपके द्वारा ग्रहण के नए संस्करण का उपयोग कर रहा हूं बहुत ही समान समस्या की तरह ...

frameworks - Codeigniter get keys of language-files -

I'm running here in an I18N-problem. I have a database in which several variables have been stored. (Ec mod_sales ) To enable I18N-my site, I have a language-file of the language-file (ec $ The-> long-> line (' Mod_sales'); ). This will return the value of that language-variable from the language-file (ec $ lang ['mod_sales'] = "sales"; ) or in German ( $ lang ['mod_sales'] = "workoff" ) There is a problem here now: I am trying to reverse the process so that key-value can be found Say lang-array that I'm driving my site in German and searching for "workoff", I want to get "mode_sales" - just like that He runs into me and discover the "sale". Is there any implementation method to get there, or do I have to handle it by array-function (if that is also possible)? I found out (with the help of CI-friends from #Comigniter): I can use the array using $ var = $ the-> lang-> ...

How to split a string with the uppercase character in iPhone -

I want to separate the string with the occurrence of uppercase letters. Suppose I have a string like "IAmABoy". I want the resulting strings like I Am A Boy. How to do this? Is there a sample code? Please show me how to do this. What is something simple about simplicity like some characters? Assume that some inputs like output string and NSStrings are supposed to be: NSUInteger length = [input string length]; (Nsuentegar i = 0; i 0 & amp; c> = 65 & amp; amp;; & amp;; & lt; = 90) {[outputString Attachment Format: @ "\ n% c" , C]; } And {[output string adenform: @ "% c", c]; }}

Read file comments from a zip file in Ruby -

I am doing Ruby, I need to read the contents of the file and comments from a zip file. There is no problem with content gem but I am unable to get the comment. Any ideas? You really want every comment from those files, on which I had a lot of time finding difficult times Here is an example of how a comment can be obtained from a file. is required 'zip / zip' zip :: zip file.open ("6.zip"). ZIPfile | P zipfile.get_entry ("90052.txt"). Comment ending

sql server - Use SQL to count cases in a certain state at a certain time -

I need to develop a query that will calculate the number of total open cases per month. I have a 'cases' table with an ID and a name, and a 'State_change' table containing a data column, a cassid column and a state. How can I calculate the number of cases in each month that there is a record with 'open' in the state, but with the closure of the state without any such record? I am using SQL Server 2000. You should close it (T-SQL): SEND MONTH (s.casedate) M, YEAR (S.Cezet) y, COUNT (CICIDIID CICID), Cncd = C on the status_places. CCD where SRT = 'Open' / * "State with 'Open' * / and C. & LT; GateDet () / *" in the past "* / and not (/ *" Record with state closed Without the '' off '' * * / selection 1 from the states where i.caseid = s.caseid and i.state = 'closed'), the group has monthly (squset), YEAR (s.casedate) Edit: A small accessory table is required to make data on all twel...

maintenance - Maintaining traceability up-to-date as project evolves -

During various projects, I needed to make sure that the use of the case model I developed during the analysis phase The project is covered. For this, I was able to use traceability and cases to some extent (also specifically identified) between the requirement statement (specific identity). In some cases, enabling traceability has made some extra efforts which I (and later proved) to be a good investment. Now, the biggest problem was that to keep this practice later, when things began to change (as a result of change requests, or as a result of the change in use) Any ideas of best practices for traceability maintenance? (This may apply to other items in the project - use cases of case and test cases, or cases of requirements and acceptance testing) Later edit devices can help, but they can detect traces or errors in traceability. Navigation may be ... but there is no warranty that traceability is up-to-date or correct after applying the change. I think that is one ...

conditional - Is there a concise way to test GET parameter combinations in PHP? -

The code below examines the GET parameter, on the page there are two choices that are ordered by a type and age group. Filter. I am exploring a method of revising the conditional which tests the type / age combination. Is this a more clear / concise way to write? // isset ($ _ request ['type']) || isset ($ _ request ['age'])) // give us some $ type = ($ _REQUEST ['type' '] ==' all '? False: (int] ($ _ request [' type ']) is required; $ Age = ($ _REQUEST [' age '] ==' all '? False: (int) ($ _ Request ['age']); // Test type of possible type / age if ($ type & age $) {$ cats = $ type} ",". $ Age;} otherwise ( $ Type) {$ cats = $ type;} Elseif ($ age) {$ cats = $ age;} and {$ cats = false;} // $ stuff with cats;} $ cat = array ($ _REQUEST ['type'] = = 'all'? False: $ (_ Request ['type']), $ _REQUEST ['age'] == 'all'? Wrong: interval ($ _ request ['age...

ms word - Can't save .doc as .xml -

What I want to achieve, is to compel MS Word to distribute specific stars in order to force. .xml to doc or .rtf file For example, something like from now on: something: *** TABLE_NAME.COLUMN_NAME *** or Some: AAATABLE_NAME.COLUMN_NAMEBBB Or something similar to me: & lt; W: p wsp: rsidR = "00537583" wsp: rsidRDefault = "00AF6BDF" wsp: rsidP = "00537583" & gt; & Lt; W: ppr & gt; & Lt; W: psttyle w: val = "default" /> & Lt; W: jc w: val = "both" /> & Lt; W: RPR & gt; & Lt; W: sz w: val = "23" /> & Lt; W: sz-cs w: val = "23" /> & Lt; / W: RPR & gt; & Lt; / W: ppr & gt; & Lt; W: r & gt; & Lt; W: RPR & gt; & Lt; W: sz w: val = "23" /> & Lt; W: sz-cs w: val = "23" /> & Lt; / W: RPR & gt; & Lt; W: t & gt; Some: AAA & lt; / W: t & gt; & Lt; / W: r> & Lt; ...

visual studio 2008 - debug session ends prematurely with vs.net 2008IE8 -

After upgrading to IE8, I'm having trouble debugging my web application (using development server). When I hit a breakpoint and start taking action on the code, then suddenly my debugging session ends abruptly. What is a clue, and tips to fix it? I have installed the Silverlight tool and chose Silverlight debugging to disable IE debugging, but nothing changed it. I could not find any fix for this, but there is some kind of solution another browser Use , I have selected Chrome, and now it seems that I can debug my code again

c++ - Templated Stl Containers -

टेम्पलेट & lt; class T & gt; वर्ग कंटेनर {टाइप किए गए एफिल & lt; T & gt; ObjectList; सार्वजनिक: ~ कंटेनर () (for typename ObjectList :: iterator item = _Container.begin (); item! = _Container.end (); आइटम ++) {if (* item) delete (* item)}}} मैं सूचक सामग्री को हटा कर कंटेनर आइटम को कैसे मुक्त कर सकता हूं? जी ++ इस कोड की अनुमति नहीं है आप ऐसा नहीं करना चाहते - कंटेनर (वस्तु के मामले में, आपके मामले में) मालिक इसमें शामिल आइटम, इसलिए उन्हें हटाने के लिए, आपको इसे आपको क्या कहना है, यह बताए जाने की आवश्यकता है: ObjectList.erase (आइटम); । चूंकि आप सभी वस्तुओं को हटाना (जाहिरा तौर पर) कर रहे हैं, तो आप इसका इस्तेमाल कर सकते हैं: ObjectList.clear (); और अपनी स्पष्ट लूप का उपयोग करके छोड़ दें। फिर, क्योंकि ऑब्जेक्टलिस्ट जाहिरा तौर पर एक std :: सूची है, आपको ऊपर से कोई भी करने की ज़रूरत नहीं है - जब आप std :: सूची को नष्ट कर देते हैं, तो यह स्वतः जो कुछ भी वस्तु शामिल है उसे नष्ट कर देता है। संपादित करें: ( ज्यादातर चाचा बन्स की टिप्पणी के जवाब में): ...

asp.net - getting client id of a control from variable -

मुझे जावास्क्रिप्ट में asp.net टेक्स्ट बॉक्स नियंत्रण (txtTest) के ग्राहक आईडी चाहिए। लेकिन यहां समस्या नियंत्रण आईडी है नीचे दिखाए गए वैरिएबल से आता है var testName = 'txtTest'; Var testCntrl = document.getElementById ('& lt;% =' + testName + '.clientID% & gt;'); लेकिन इसका फेंकना CS1012: चरित्र में बहुत अधिक अक्षर क्या कोई भी मदद कर सकता है .. .. & lt;% = aspControlID.ClientID%> एक सर्वर साइड नियंत्रण है, लेकिन आप कोशिश कर रहे हैं इसे करने के लिए एक clientide चर नाम पारित करने के लिए परीक्षण के समय तक 'txtTest' के बराबर सेट बहुत देर हो चुकी है, आप ग्राहक पर पहले से ही हैं। सर्वर साइड क्लाइंटआईड्स को प्राप्त करने के लिए कई विकल्प हैं। 1) आप सभी नियंत्रण आईडी को पूर्व-लोड कर सकते हैं जिसे आप जानते हैं कि आप इस तरह की ज़रूरत पर जा रहे हैं, वे उनसे पूछते हैं (वह jquery का उपयोग करता है) जब आप अपने तत्वों की आवश्यकता होती है। var id = {TxtSymbol: "# & lt;% = txtSymbol.ClientID% & gt;", पृष्ठ कंटें...

java - How do I switch to another subversion branch in Intellij? -

What is the concept of changing branches in IntelliJ? I should either be blind or stupid ... I would have thought that the "switch to copy" option or something like that, but none is ... explanation Edit for: My previous IDE had a simple "switch to switch" option, which updates all the files that are separated from the current branch / trunk. There seems to be a completely different approach to IntelliJ, which I do not understand. Help is not very helpful. Helpful keywords, links or hints greatly appreciate. Thank you. Just got to know that switching branches update dialog (VCS -> update project, ⌘T), where I I want to choose any branch, tag or amendment.

java - How to best use JTidy with a Spring servlet container? -

I have a Java servlet container using the Spring Framework, all the things generated by JSP, using spring to wire Pages are ready. The resultant HTML sent to the user is not as good as I would like. I want to send the HTML correctly before sending the client browser. I will set it to work in development and stop production; This is a winner in my vision, because this will give me more ease in maintenance. How to clean that work in the spring? Why do you want to do this? The best part is to remove all the white spaces and compact the HTML as much as possible. Users appear to submit HTML, and mostly do not care about its composition and indentation. If you want users to see HTML, they can use an HTML makeup on HTML on their machine. More info The JTD is the one you can apply on your JSPS. Just add the following lines to jtidy jar and web.xml for web-INF / Lib: & lt; Filter & gt; & Lt; Filter-name & gt; JTidyFilter & lt; / Filter-name & gt; ...

Is it unusual for a web service call to have an "out" parameter? -

Is this unusual for the "out" parameter for a web service call? If so, why? I am using the C # web service and the web site user will also be the C # app. If you are referring to the parameter at the C # level in the ASP.Net Web service, then I It does not seem absolutely unusual. Your external parameter will only become the child element of the reaction element. Here is a small web service that has a web method in which the parameters are: [WebService (namespace = "http://begen.name/xml/namespace/2009/10/samplewebservicev1") ] Public class sample WebServiceV1: WebService {[WebMethod] Public Zero WebMethodWithOutParameters (String outParam1, String OutParam2 out) {OutParam1 = "Hello"; Outamparam 2 = "Web!"; }} With the above web method, SOAP requests look like this: POST / sample WebServiceV1.asmx HTTP / 1.1 host: Local Host Content -type: text / xml; Charset = utf-8 Content-Length: SOAPAction Length: "http://begen.name/x...

compression - Does the common HTTP server implementation decompress POSTed form data? -

If I gzip the post request request form, an HTTP server will disinfect it, or it only works in other ways Is (server -> customer)? Which web server are you using? I am assuming that you are posting from within a program. Although it is possible to send jaded data to a server, but the browser does not do this, because the server generally does not show how it accepts encoding. You can see how a server accepts with the option command: curl-iX option http: // localhost: 8080 / HTTP / 1.1 200 OK date: Tuesday, October 20 2009 00:54: 29 GMT server: Apache / 2.2.8 (Unix) mod_ssl / 2.2.8 OpenSSL / 0.9.8 AAV / 2 PHP / 5.2.6 SVN / 1.6.5 Proxy_HTML / 3.0.0 Allow: Received , Head, post, option, however, if you control both server and client, then the data stream you prefer Can send. For example, in both directions, but not dependent on the web server for compression / decompression.

sql - How to mark counted rows as deleted? contin'd from previous question -

Okay I realized that from my previous question: To update this main table The method used to count using the secondary table, but since this query will be in a SQL job, how can I just delete the rows to count, and making sure I do not put any new lines in the secondary table? If I am reading this, you (in your first question) with the number of unique IPs Records are associated with each employee who want to update the selection, and now in the same process the records come out from the list of those selections, which make those numbers - while no record was added since the selectioncount was updated. 1) is a primary key in your selection table, and And 2) A row line was created, so it would be very easy. The absence of both confused things. So we will do it in a weird way (assuming you are unable to change your schema). Believes that you are using SQL 2005 or 2008: I'm guessing my databases here DECLARE @TempIPs TABLE (EmployeeID int, ipaddress Varchar (25)) DEL...

linq - How to use isnull type decision in linqdatasource orderby? -

I have a SQL stored procedure, which will be used respectively in order to order items from the date of the latest reply date. , Or the date of posting is zero: Example: ORDER BY isnull (rtb.LatestReplyDate, CB_TOPIC_DATE_POSTED) DESC I work it in order according to order of a linqdatasource I have been trying, no benefit till now: Example: I know that there is no validity there Yes, but I just do not know what will work, if anything. I tried ?? Any ideas as an operator? - addendum orderbie ( P = & gt; P.Litt; YourCompareVariant & gt; == Nil; P. & lt; If Null & gt;: P. & lt; IfNotNull & gt;); In your case: commandb (p = & gt; p.LatestReplyDate == blank; P. latest delete: p.TopicDatePosted);

jar - What is the problem when javac compiler creates a jarfile with lowercase class file names? -

When I run the javac compiler, this code compiles and creates a JR file, But the class files inside the jar are all in the lower case. However, there are both lower and upper case names of the sections within source files, the result is that I can not compile other projects which are dependent on this jar. I am getting the same issue and this clearly is in the dynamic view. I have unchecked the "Case Incentive MVFS" from the Control Panel clearly I and MVFS restart (the system may need to be restarted)

JavaScript/jQuery check broken links -

I have developed a small javascript / jquery program to use the collection of PDF files for internal use. And if I really existed the file then I should be informed about a PDF file. Is there any way to determine the program that the link to the file is broken? if so, how? Any guide or suggestion is deployed. If the files are on the same domain, then you can use AJAX to test for your survival As it has been said; However, you should not use the GET method, simply HEAD and then the HTTP status for expected value (200, or less 400 ). It was a but it just did not seem to be a head. Instead, a simple method is given here: function urlExists (url, callback) {var xhr = new XMLHttpRequest (); Xhr.onreadystatechange = function () {if (xhr.readyState === 4) {callback (xhr.status & lt; 400); }}; Xhr.open ('HEAD', URL); Xhr.send (); } UrlExists (someUrl, function (present) {console.log ('"% s" exists?', Some url exists,;)});

.net 3.5 - Windows Workflow Dynamic, User-Created Workflows -

I have a client who is interested in using (WF) technology in a web-driven application. I have a .NET Developer, but I have no experience with the WF or SharePoint workflow. Most of the customers who want to do are straight-forward, except that they want the end users to be able to create / edit their own custom workflow. In my brief research in WF, it does not seem like how this generally works, is it possible that users are allowed to create workflows themselves, or is it really a custom ASP.NET MVC application, or maybe Is that a SharePoint application? Users are considered to be one of the stron points of WF to be able to change the workflow. However, the whole model with WF3 has been prepared for code generation and is not a markup, so it is hard to do. It is not impossible because you can use pure markup workflow but it is difficult. This story is considered very good with WF4 because all workflows are pure markup and no code is included in it. All codes are in predefi...