Search Results

Search found 1742 results on 70 pages for 'combine'.

Page 45/70 | < Previous Page | 41 42 43 44 45 46 47 48 49 50 51 52  | Next Page >

  • Send post data while opening SSE connection

    - by Prosto Trader
    I'm trying to establish SSE connection and do some long-taking actions on server-side, informing user about how it goes through SSE events. Actually, I don't understand how would I send some data along with new connection. I have to combine regular ajax with new EventSource or there is a way to transfer post data inside that event? Here is what I have so far, and I need to send pretty big JSON with the request. Is it possible or the only way to send data is GET? var source = new EventSource('/terminal/ajax-put-packet-trade-order/');

    Read the article

  • removing dashboard menu options for the user role editor

    - by styler
    I want to remove some of the dashboard menu tabs on my wordpress site using this code: //Remove some menu options function remove_menus () { global $menu; $restricted = array(__('Dashboard'), __('Posts'), __('Media'), __('Contact'), __('Links'), __('Pages'), __('Appearance'), __('Tools'), __('Users'), __('Settings'), __('Comments'), __('Plugins')); end ($menu); while (prev($menu)){ $value = explode(' ',$menu[key($menu)][0]); if(in_array($value[0] != NULL?$value[0]:"" , $restricted)){unset($menu[key($menu)]);} } } add_action('admin_menu', 'remove_menus'); At the moment this removes the menus from all user roles, how could I update this to just apply to editors? Ive also got this snippet of code but dont know how to combine it with what I have: $editor = get_role(‘editor’); $editor->remove_cap(‘publish_pages’);

    Read the article

  • Concatenate text files with Windows command line, dropping leading lines

    - by James
    I need to concatenate some relatively large text files, and would prefer to do this via the command line. Unfortunately I only have Windows, and cannot install new software. type file1.txt file2.txt > out.txt allows me to almost get what I want, but I don't want the 1st line of file2.txt to be included in out.txt. I have noticed that more has the +n option to specify a starting line, but I haven't managed to combine these to get the result I want. I'm aware that this may not be possible in Windows, and I can always edit out.txt by hand to get rid of the line, but is there a simple way of doing it from the command line?

    Read the article

  • Is there a combination of "LIKE" and "IN" in SQL?

    - by Techpriester
    Hi folks. In SQL I (sadly) often have to use "LIKE" conditions due to databases that violate nearly every rule of normalization. I can't change that right now. But that's irrelevant to the question. Further, I often use conditions like WHERE something in (1,1,2,3,5,8,13,21) for better readability and flexibility of my SQL statements. Is there any possible way to combine these two things without writing complicated sub-selects? I want something as easy as WHERE something LIKE ('bla%', '%foo%', 'batz%') instead of WHERE something LIKE 'bla%' OR something LIKE '%foo%' OR something LIKE 'batz%' I'm working with MS SQl Server and Oracle here but I'm interested if this is possible in any RDBMS at all.

    Read the article

  • How to make flyspell bypass some words by context?

    - by manu
    Hi, I use Emacs for writing most of my writings. I write using reStructuredText, and then transform them to LaTeX after some preprocessing since I write my citations á-la LaTeX. This is an excerpt of one of my texts (in Spanish): En \cite[pp.~XXVIII--XXIX]{Crnkovic2002} se brindan algunos riesgos que se pueden asumir con el desarrollo basado en componentes, los This text is processed by some custom scripts that deals with the \cite part so rst2latex can do its job. When I activate flyspell-mode it signals most of the citation keys as spelling errors. How can I tell flyspell not to spellcheck things within \cite commands. Furthermore, how can I combine rst-mode and flyspell, so that rst-mode would keep flyspell from spellchecking the following? reST comments reST code literal reST directive parameters and arguments reST raw directive contents Any ideas?

    Read the article

  • How to handle multiple projects in a small team

    - by meo
    We just started to use scrum for our project management. We are a very small team (2 developers, 1 UI/Web-deisgner ) and we have a lot of running projects at once. How do you handle having multiple projects running at once in the scrum model? Most of the time we have a main projects and some small ones. How do you combine multiple sprints efficiently? PS: I'm not sure stackoverflow is the right place to ask this kind of question, i hope there is a scrum master out there reading this.

    Read the article

  • Paths when both including and requesting AJAX

    - by Cristian
    I was wondering if there is a way of making a relative path to the main folder (where the index.php lies) from every file that needs to be included or requested by AJAX. I want to combine both AJAX and PHP include so first time the page loads with PHP, and then to be able to refresh parts of the page with AJAX, but the files are the same and lie in subfolders. I'm having problems with the path and although I can set an absolute path, then I have to change it every time the server changes. I want a relative path to where my project is, but not DOCUMENT_ROOT, because that one doesn't work with aliases. (or do you know how to make it work with aliases? ) Thanks !

    Read the article

  • Why can't there be an "ultimate" programming language? [closed]

    - by sub
    There is an uncountable sum of programming languages out there. They obviously all have their pro's and con's - but why can't there be one to "beat them all"? The main part of a programming language is it's syntax and what's possible with it. The rest are usually only a bunch of libraries, frameworks and extensions wrapped around it. So couldn't you combine all the great aspects and experiences gained from the thousands of programming languages out there to build one with a syntax that fits every task? Wouldn't it be better having only one programming language? I see only problems with the current amount of the ones in use. Why can't there be a perfect language when thinking of syntax, constructs and typing?

    Read the article

  • Creating a view linking three different node types with two node references

    - by mikesir87
    I have the following content types: Camp - the top level type Registration Information - contains node reference to Camp called Camp Medical Release Form - contains node reference to registration information called Camper I would like to create a View that takes the nid for the Camp, and pulls out all the fields for the Registration Info and Medical Release Form. I'm having trouble figuring out how to set up the various arguments/relationships. I haven't done something that's referenced more than two types. I know it would be smart/best to just combine the Registration Info and Medical Release Form, since it's a 1:1 mapping, but we can't. So... any help would be appreciated!

    Read the article

  • Time diff calculations where date and time are in seperate columns

    - by pedalpete
    I've got a query where I'm trying to get the hours in duration (eg 6.5 hours) between two different times. In my database, time and date are held in different fields so I can efficiently query on just a startDate, or endDate as I never query specifically on time. My query looks like this SELECT COUNT(*), IFNULL(SUM(TIMEDIFF(endTime,startTime)),0) FROM events WHERE user=18 Sometimes an event will go overnight, so the difference between times needs to take into account the differences between the dates as well. I've been trying SELECT COUNT(*), IFNULL(SUM(TIMEDIFF(CONCAT(endDate,' ',endTime),CONCAT(startDate,' ',startTime))),0) FROM events WHERE user=18 Unfortunately I only get errors when I do this, and I can't seem to combine the two fields into a single timestamp.

    Read the article

  • WPF InotifyPropertyChanged and view models

    - by Joel Barsotti
    So I think I'm doing something pretty basic. I know why this doesn't work, but it seems like there should be a straight foward way to make it work. code: private string fooImageRoot; // .... public BitmapImage FooImage { get { URI imageURI = new URI(Path.Combine(fooImageRoot, CurrentFooTypes.FooObject.FooImageName)); return imageURI; } } So CurrentFOoTypes and FooObject also supports INotifyPropertyChanged. So If I bind a TextBlock to CurrentFooTypes.FooObject.FooImageName, if either fooObject or FooImageName change the textblock updates. How can I subscribe my viewmodel object to recieve updates in a similiar fasion.

    Read the article

  • can I debug my web proejct and wcf project on same vs 2008 instance ?

    - by dotnetcoder
    I have two projects in my solution 1- asp.net web project. 2- wcf serivce project. 3- other common projects between two listed above Currently on the local dev machine I have to run two visual studio instance to run both projects in debug mode. That makes the system run out of resources as these projects share some other project in the soultion which are heavy in files. Is there a way I can hookup the wcf project on a sinlge visual stodio instance that I am using to debug the asp.net web applicaiton. I do not want to combine the web and wcf project in to one. Have already considred this option. thanks for sharing your thoughts in advance.

    Read the article

  • Help with Magento and related products

    - by Anthony
    I have a customer product page that literally lives beside the catalog/product/view.phtml page. It's basically identical to that page with a few small exceptions. It's basically a 'product of the day' type page so I can't combine it with the regular product page since I have to fetch the data from the DB and perform a load to get the product information $_product = Mage::getModel('catalog/product')->load($row['productid']); To make a long story short, everything works (including all children html blocks) with the singular exception of the related products. After the load I save the product into the registry with Mage::register('product', $_product); and then attempt to load the related products with: echo $this->getLayout()->createBlock('catalog/product_view')->setTemplate('catalog/product/list/related.phtml')->toHtml();` All of which give back the error: Fatal error: Call to a member function getSize() on a non-object in catalog/product/list/related.phtml on line 29`, and line 29 is <?php if($this->getItems()->getSize()): ?>`. Any help getting the relateds to load would be appreicated.

    Read the article

  • Excel PivotTable : Calculated Field / Item for Period Comparison

    - by dino76
    HI All, If I have a PivotTable in Excel 2007 with a date field. I understand that I can group the date by day, month or even year using Group Field (Years & Months). If I combine with product perspective, the PivotTable may look like this Sum of Sales_Total | Column Labels Row Labels | PRODUCT-001 | PRODUCT-002 | Grand Total - 2006 | 2000 | 1500 | 3500 Jan | 1700 | 800 | 2500 Feb | 300 | 700 | 1000 - 2007 | 1000 | 1500 | 2500 Jan | 700 | 800 | 1500 Feb | 300 | 700 | 1000 - 2008 | 600 | 700 | 1300 Jan | 600 | 700 | 1300 Now, what I want to do is to compare Jan 2008 - Jan 2006 and Jan 2007 - Jan 2006. Something like this : | Column Labels | PRODUCT-001 | | ... Row Labels | Sum of Sales | Sum of Last Sales | - 2006 | 2000 | | Jan | 1700 | | Feb | 300 | | - 2007 | 1000 | 2000 | Jan | 700 | 1700 | Feb | 300 | 300 | - 2008 | 600 | 1000 | Jan | 600 | 700 | Is it possible ? If so, how to do that ? Thanks, D. Chopins

    Read the article

  • Regarding PID Shell Script

    - by arav
    I am calling another shell script testarg.sh within my main script. the logfiles of testarg.sh are stored in $CUSTLOGS in the below format testarg.DDMONYY.PID.log example: testarg.09Jun10.21165.log In the main script after the testarg process gets completed i need to grep the log file for the text "ERROR" and "COMPLETED SUCCESSFULLY". How do i get the PID of the process and combine with DDMONYY for grepping. Also i need to check whether file exists before grepping $CUSTBIN/testarg.sh $CUSTBIN/testarg.sh rc=$? if [ $rc -ne 0 ]; then return $CODE_WARN fi

    Read the article

  • Is it possible to open a pipe-based filehandle which prints to a variable in perl?

    - by blackkettle
    Hi, I know I can do this, ------ open(F,"",\$var); print F "something cool"; close(F); print $var; ------ or this, open(F, "| ./prog1 | ./prog2 tmp.file"); print F "something cool"; close(F); but is it possible to combine these? The semantics of what I'd like to do should be clear from the following, open(F,"|./prog1 | ./prog2", \$var); print F "something cool"; close(F); print $var; however the above clearly won't work. A few minutes of experimenting and googling seems to indicate that this is not possible, but I'd like to know if I'm stuck with using the `` to capture the output.

    Read the article

  • Combining several static archives into a new one

    - by knight666
    I'm making a game engine for mobile devices. I want to compile my code, link it against a few static libraries and then combine my compiled code with those static libraries to form a new static library. However, my Google Fu is abandoning me. Suppose I have static libraries a.a, b.a and c.a and my code. I want to compile all that into awesome.a. How can I do that? I'm using CodeSourcery's arm-none-linux-gnueabi-ar by the way. Thanks in advance.

    Read the article

  • Macro - To create one [.csv] file from/using multiple workbooks, kept in a folder, containing multi

    - by AJ
    Hello, I have more than one Excel Workbooks containing multiple worksheets in each of them. I would like to have a macro which help me to create (combine the information from) all the worksheets into one pipe [|] delimited [.csv] file. These sheets should be combined/appended into the [.csv] file, in the same order these worksbooks appear in a folder and in the order sheets appear in these workbooks. The macro should ask for a delimiter/separator specific to me and the input and output path based on my selection. It would be great if the output [.csv] file is names as "foldername" + "Output.csv" Thank you, Best Regards - AJ

    Read the article

  • CSS Sprites : Mysterious Concept Explored ?

    - by Rachel
    I have 3 different images and now I want to create an sprite using css so that I am reducing HTTP Request. I am totally new to this concept and have not idea as to how to approach this. Can anyone suggest me what would be best bet for me ? Also I have seen there are some CSS Sprite generator engines where in you submit .zip folder containing your images and than they would combine it. I tried doing that but did not understood of what was happening and so any guidance regarding creating and using CSS sprites would be highly appreciated. Update: I have gone through the AList Part but it was not very clear to me. Can anyone explain the use case of CSS Sprites using an example ? Thanks.

    Read the article

  • sql server db deployment script ignoring constraints etc until commit

    - by Daniel
    Hi all, I am planning on doing a database deployment script for sql server 2005. Currently we have a tool that will run all of the tables, foreign keys, indexes and then data, each of which is located in a separate file with a certain extension (eg. tab, .kci, .fky) and the tool just runs *.tab, *.kci, *.fky into the db etc. Could I possibly combine all of thse into one file and have them run ignoring referential integrity until they are all complete, I would turn it on before we started inserting test data. It is just unmanageable having to maintain 4 or 5 different types of scripts for one table. Are there any issues I should be aware of? Cheers

    Read the article

  • Help in formulating sql query

    - by AJ
    Here is my scenario Table 1: GID || Info1 Table 2: GID || Tb1GID (refers to GID of Table1) || Info2 Table 3: GID || Info3 Table 4: GID || Tb2GID (refers to GID of Table2 || Tb3GID (refers to Table3 GID || Value Now I have to build an sql query to get the value, given a particular Info1, Info2, Info3. Essentially, I have to get the GID, of table 1 using info1, GID of table to , by mapping info2 and GID of table 1. And then get the GID of table 3 using info 3. And combine these to GIDs to get the value in table 4. What is the most optimal way of constructing an sql query for this one?

    Read the article

  • How to UNION ALL two SELECT statements?

    - by Lisa
    I have 2 tables, one looks like this: TABLE ONE id | Last Name | First Name | Username | Password | Secret Question and another that looks like this: TABLE TWO id | Hobby | Country | I want to combine a Select statement that grabs data from both tables and output the results. The following code: $select = mysql_query(" SELECT * FROM table_one WHERE Username = 'Bob' UNION ALL SELECT * FROM table_two WHERE Hobby = 'Baseball' "); while ($return = mysql_fetch_assoc($select)) { $userName = $return['Username']; $hobby = $return['Hobby']; } echo "$userName likes $hobby"; results in a The used SELECT statements have a different number of columns error, what am I doing wrong?

    Read the article

  • Combining packages from different projects into a single project in eclipse

    - by primal
    Hi, As part of the Android application I am developing in eclipse, I need to combine two packages from different projects into a single project. I tried copying the files in the package of the second project under the src folder of the first folder and copied other files required for second package into the res folder of the first project. But the auto-generated Java files i.e R.java doesn't get updated on copying. I tried right clicking on the project and clicking on Android Tools - Fix Project Properties. But nothing changed. Any pointers on what I am doing wrong much be appreciated.

    Read the article

  • How do a search a table for similar records and displaying count - Ruby on Rails

    - by bgadoci
    I have created a table in my Ruby on Rails application that I am building called Tags. It is a blog application so I allow the user to associate tags with a post and do this through a :posts, :has_many = tags and Tag belongs_to :post association. Now that I have my Tags table I am trying to see how I would render the view such that it displays the tag and tag count. (it should be noted that I am trying to render this in the /views/posts/index.html.erb file). For instance, if there are 10 entries in the Tag table for tag_name Sports. How can I display Sports (10) in the view. I am not looking to do this for a specific tag but rather, somehow search the table, combine like tags and display a list of all tags with counts next to them. (I really want these to be a link to a list of posts that contain that tag but I learned early on only to ask one question at a time). Hope that makes sense.

    Read the article

  • Copy first row in excel workbook to a new excel workbook

    - by user1667414
    How do I get the first row in an excel workbook & save it to a new excel workbook using .net c#? I dont know the amount of columns so need to get entire row. This what I have but the new workbook is blank (no row copied) Excel.Workbook xlWorkbook = xlApp.Workbooks.Open(file); Excel._Worksheet xlWorksheet = xlWorkbook.Sheets[1]; Excel.Range xlRangeHeader = xlWorksheet.get_Range("A1", "A1").EntireRow; Excel.Workbook xlWorkbookNew = xlApp.Workbooks.Add(); Excel._Worksheet xlWorksheetNew = xlWorkbookNew.Sheets[1]; xlWorksheetNew.get_Range("A1", "A1").EntireRow.Value = xlRangeHeader; xlWorkbook.Close(false); xlWorkbookNew.SaveAs(Path.Combine(sDestination, Path.GetFileName(file)), fileFormat); xlWorkbookNew.Close(true);

    Read the article

< Previous Page | 41 42 43 44 45 46 47 48 49 50 51 52  | Next Page >