Search Results

Search found 319 results on 13 pages for 'awkward'.

Page 6/13 | < Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >

  • Move unity launcher to bottom of the screen

    - by argvar
    I have Ubuntu 13.04 DESKTOP version and for some odd reason I'm told that the Unity launcher cannot be moved to the bottom of the screen because of several reasons: 1. Canonical wants it there so it fits with their overall design goals, namely when it comes to touchscreen devices and netbooks. This in my mind totally ignores the fact that most Ubuntu users are DESKTOP users. No matter what Canonicals long term goal is, it surely mustn't be at the expense of needs of their core user base. 2. Most monitors are widescreen, the launcher is more compact where it is. This is not only taking away the users choice, but is also a wrong assessment. Widescreen monitors can sometimes be rotated on a pivot, giving it a portrait aspect. By displaying the Unity launcher on the left side it takes up a lot of space. Many desktop users have multiple monitors, and having the launcher on the left side of each monitor is very awkward. Also, many websites are catered to fit on a half 1920 display, so you can have two browser windows open side-by-side with all content visible. The placement of the Unity launcher takes away the horizontal space meaning there's less room for each browser window, and you'll see the right side of the web pages being occluded. Any suggestion to simply hide the Unity launcher, or "Canonical knows best" or "get used to it" are unwelcome and totally ignores the above points. Linux is about choice. Canonical's stubbornness with the Unity launcher placement is inconsistent with what Linux is about.

    Read the article

  • I just received a complaint from a user of the website I maintain. Should I do anything?

    - by Chris
    I was sent sent a large wall of text from a user of the website I maintain at my job. They are clearly upset for having to deal with a horribly outdated web application that has not seen any serious updates in over 6+ years. No refactoring has been done, the code quality is terrible, the security unchecked, policy compliances ignored, in addition to being ugly and frankly embarrassing. Keep in mind this is a small business but the website is used by hundreds daily. I'm one of two programmers there, and I've been working there for two years. This person says they are about my age (22) and understand technology (but can't use proper grammar). The complaint mentioned awkward pages and actions on the website, but they don't even have a clue as to the depth of the flaws in this website. Now, I would love to honestly tell them that there's a lot wrong with this company and that this application was built when we were in high school. And that while it's not my fault that the website is terrible, I'm the one in position to fix it. But on the other hand, I could just say nothing and ignore it. Would doing this publicly have any advantage to future employees (showing integrity) or would it just be a completely pointless mistake? Odds are, even if I respond only that one person will ever read it. Regardless, I'm probably just going to ignore it and continue starting my project to refactor the website.

    Read the article

  • How to Use Vim-Style Keyboard Shortcuts for OS X Tab Navigation

    - by The Geek
    After switching to OS X when I got a new MacBook Air, one of the first things I needed to duplicate was my extremely customized AutoHotkey setup — the most important of which is using the J and K keys to navigate throughout tabbed windows easily. Yeah, I’m a Vim user. I’ve never been a fan of having to use CTRL + TAB to switch from one tab to the next — to start with, you have to move your hands from the home row, and it’s awkward, and why should I have to do that just because somebody decided that keyboard shortcut before tabs became popular? If you think about it, if tabbed browsers were popular back when keyboard shortcuts were being invented, they would have definitely reserved some of the good shortcuts for switching tabs. On Windows, I’ve always used an AutoHotkey script to make things the way I wanted it:  ALT + J and ALT + K for selecting previous and next tabs. Once you get used to it, it’s extremely awesome, and so much faster than using CTRL + TAB. Of course, I also hacked CTRL + T and CTRL + W into ALT + T and ALT + W so I could open new tabs and close them without moving my hands from the home row. Over on OS X, it turns out that it’s incredibly simple and easy to use CMD + J and CMD + K for next/previous tab navigation, and it works in most applications that support tabs, like Terminal, Safari, or Google Chrome.    

    Read the article

  • State Changes in a Component Based Architecture [closed]

    - by Maxem
    I'm currently working on a game and using the naive component based architecture thingie (Entities are a bag of components, entity.Update() calls Update on each updateable component), while the addition of new features is really simple, it makes a few things really difficult: a) multithreading / currency b) networking c) unit testing. Multithreading / Concurrency is difficult because I basically have to do poor mans concurrency (running the entity updates in separate threads while locking only stuff that crashes (like lists) and ignoring the staleness of read state (some states are already updated, others aren't)) Networking: There are no explicit state changes that I could efficiently push over the net. Unit testing: All updates may or may not conflict, so automated testing is at least awkward. I was thinking about these issues a bit and would like your input on these changes / idea: Switch from the naive cba to a cba with sub systems that work on lists of components Make all state changes explicit Combine 1 and 2 :p Example world update: statePostProcessing.Wait() // ensure that post processing has finished Apply(postProcessedState) state = new StateBag() Concurrently( () => LifeCycleSubSystem.Update(state), // populates the state bag () => MovementSubSystem.Update(state), // populates the state bag .... }) statePostProcessing = Future(() => PostProcess(state)) statePostProcessing.Start() // Tick is finished, the post processing happens in the background So basically the changes are (consistently) based on the data for the last tick; the post processing can a) generate network packages and b) fix conflicts / remove useless changes (example: entity has been destroyed - ignore movement etc.). EDIT: To clarify the granularity of the state changes: If I save these post processed state bags and apply them to an empty world, I see exactly what has happened in the game these state bags originated from - "Free" replay capability. EDIT2: I guess I should have used the term Event instead of State Change and point out that I kind of want to use the Event Sourcing pattern

    Read the article

  • Good practice on Visual Studio Solutions

    - by JonWillis
    Hopefully a relativity simple question. I'm starting work on a new internal project to create tractability of repaired devices within the buildings. The database is stored remotely on a webserver, and will be accessed via web API (JSON output) and protected with OAuth. The front end GUI is being done in WPF, and the business code in C#. From this, I see the different layers Presentation/Application/Datastore. There will be code for managing all the authenticated calls to the API, class to represent entities (business objects), classes to construct the entities (business objects), parts for WPF GUI, parts of the WPF viewmodels, and so on. Is it best to create this in a single project, or split them into individual projects? In my heart I say it should be multiple projects. I have done it both ways previously, and found testing to be easier with a single project solution, however with multiple projects then recursive dependencies can crop up. Especially when classes have interfaces to make it easier to test, I've found things can become awkward.

    Read the article

  • which technology or strategy a new / inexperienced freelancer should use to earn profit? [closed]

    - by w3softdev
    this question has re-posted by me in the following group if you find suitable to answer this question then please click on the link attached here or copy paste this in your browser.. http://answers.onstartups.com/questions/32767/which-technology-or-strategy-a-new-inexperienced-freelancer-should-use-to-earn Well it is my very first Question in this section and i really don't know whether my query relate to this section or not. anyway i have some awkward query. (however, it is like a bit story but i guess it is necessary to know some background knowledge of me.) Actually I m fresh recent grad who has just started his freelancing work. In due course i have got a project to develop website for a middle scale business (travel agent). As I don't trust on my client whether he will pay to me in full or not after the completion of website, i want to use cheaper and efficient technology so that how much he would pay I could got at least few units of % of profit. As i have learnt ASP.NET and when I inquired about the expense in Hosting of my website i got the recommendation to develop my web app using the combination PHP and MYSQL instead the asp.net + ms sql. And the problem is I don't know PHP. should I learn PHP and or work in what i m comfortable with and should try to cover whole deserved money. (as it is my first project so i m also advised that i may got some loss in starting but contrary to this i don't want to go in loss and want to earn appropriate profit)

    Read the article

  • On Developing Web Services with Global State

    - by user74418
    I'm new to web programming. I'm more experienced and comfortable with client-side code. Recently, I've been dabbling in web programming through Python's Google App Engine. I ran into some difficulty while trying to write some simple apps for the purposes of learning, mainly involving how to maintain some kind of consistent universally-accessible state for the application. I tried to write a simple queueing management system, the kind you would expect to be used in a small clinic, or at a cafeteria. Typically, this is done with hardware. You take a number from a ticketing machine, and when your number is displayed or called you approach the counter for service. Alternatively, you could be given a small pager, which will beep or vibrate when it is your turn to receive service. The former is somewhat better in that you have an idea of how many people are still ahead of you in the queue. In this situation, the global state is the last number in queue, which needs to be updated whenever a request is made to the server. I'm not sure how to best to store and maintain this value in a GAE context. The solution I thought of was to keep the value in the Datastore, attempt to query it during a ticket request, update the value, and then re-store it with put. My problem is that I haven't figured out how to lock the resource so that other requests do not check the value while it is in the middle of being updated. I am concerned that I may end up ticket requests that have the same queue number. Also, the whole solution feels awkward to me. I was wondering if there was a more natural way to accomplish this without having to go through the Datastore. Can anyone with more experience in this domain provide some advice on how to approach the design of the above application?

    Read the article

  • Can an Employer turn you down if you have said the fact about current work culture being bad [closed]

    - by MansonRix
    I had recently an interview where I scored good in 1st two round of technical interview . Then in the 3rd round was the managerial round where the guy started about my experience and whether I have vaptured any requirement and handled and trained any teams. This went pretty well for around 50 mins . Then there was the awkward question , Interviewer: why amI looking for a change? Me: coz I want to explore my carrier options? Interviewer: But your current company is big enough and you can explore options over there? (This was supposedly the trap) Me: Apart from that I am missing the flexibilty of working with Us and Europe based company as my current company is not that flexible. Interviewer: What exactly you don't find flexible. Me: The login time . Even if you get late by 1sec you might have to explin. Though this is not a big problem , still I will prefer flexibilty as we are working really hard. Interviewer: Allright ( Then couple of more questions) , Hope to C U Ya , that's pretty much it . Now I called up HR and they say , they are yet to get the feedback from Interviewer. Did I screw it? I mean does some one really have to pretend always by saying positive things about company and manager though not saying negative things?

    Read the article

  • eBooks on iPad vs. Kindle: More Debate than Smackdown

    - by andrewbrust
    When the iPad was presented at its San Francisco launch event on January 28th, Steve Jobs spent a significant amount of time explaining how well the device would serve as an eBook reader. He showed the iBooks reader application and iBookstore and laid down the gauntlet before Amazon and its beloved Kindle device. Almost immediately afterwards, criticism came rushing forth that the iPad could never beat the Kindle for book reading. The curious part of that criticism is that virtually no one offering it had actually used the iPad yet. A few weeks later, on April 3rd, the iPad was released for sale in the United States. I bought one on that day and in the few additional weeks that have elapsed, I’ve given quite a workout to most of its capabilities, including its eBook features. I’ve also spent some time with the Kindle, albeit a first-generation model, to see how it actually compares to the iPad. I had some expectations going in, but I came away with conclusions about each device that were more scenario-based than absolute. I present my findings to you here.   Vital Statistics Let’s start with an inventory of each device’s underlying technology. The iPad has a color, backlit LCD screen and an on-screen keyboard. It has a battery which, on a full charge, lasts anywhere from 6-10 hours. The Kindle offers a monochrome, reflective E Ink display, a physical keyboard and a battery that on my first gen loaner unit can go up to a week between charges (Amazon claims the battery on the Kindle 2 can last up to 2 weeks on a single charge). The Kindle connects to Amazon’s Kindle Store using a 3G modem (the technology and network vary depending on the model) that incurs no airtime service charges whatsoever. The iPad units that are on-sale today work over WiFi only. 3G-equipped models will be on sale shortly and will command a $130 premium over their WiFi-only counterparts. 3G service on the iPad, in the U.S. from AT&T, will be fee-based, with a 250MB plan at $14.99 per month and an unlimited plan at $29.99. No contract is required for 3G service. All these tech specs aside, I think a more useful observation is that the iPad is a multi-purpose Internet-connected entertainment device, while the Kindle is a dedicated reading device. The question is whether those differences in design and intended use create a clear-cut winner for reading electronic publications. Let’s take a look at each device, in isolation, now.   Kindle To me, what’s most innovative about the Kindle is its E Ink display. E Ink really looks like ink on a sheet of paper. It requires no backlight, it’s fully visible in direct sunlight and it causes almost none of the eyestrain that LCD-based computer display technology (like that used on the iPad) does. It’s really versatile in an all-around way. Forgive me if this sounds precious, but reading on it is really a joy. In fact, it’s a genuinely relaxing experience. Through the Kindle Store, Amazon allows users to download books (including audio books), magazines, newspapers and blog feeds. Books and magazines can be purchased either on a single-issue basis or as an annual subscription. Books, of course, are purchased singly. Oddly, blogs are not free, but instead carry a monthly subscription fee, typically $1.99. To me this is ludicrous, but I suppose the free 3G service is partially to blame. Books and magazine issues download quickly. Magazine and blog subscriptions cause new issues or posts to be pushed to your device on an automated basis. Available blogs include 9000-odd feeds that Amazon offers on the Kindle Store; unless I missed something, arbitrary RSS feeds are not supported (though there are third party workarounds to this limitation). The shopping experience is integrated well, has an huge selection, and offers certain graphical perks. For example, magazine and newspaper logos are displayed in menus, and book cover thumbnails appear as well. A simple search mechanism is provided and text entry through the physical keyboard is relatively painless. It’s very easy and straightforward to enter the store, find something you like and start reading it quickly. If you know what you’re looking for, it’s even faster. Given Kindle’s high portability, very reliable battery, instant-on capability and highly integrated content acquisition, it makes reading on whim, and in random spurts of downtime, very attractive. The Kindle’s home screen lists all of your publications, and easily lets you select one, then start reading it. Once opened, publications display in crisp, attractive text that is adjustable in size. “Turning” pages is achieved through buttons dedicated to the task. Notes can be recorded, bookmarks can be saved and pages can be saved as clippings. I am not an avid book reader, and yet I found the Kindle made it really fun, convenient and soothing to read. There’s something about the easy access to the material and the simplicity of the display that makes the Kindle seduce you into chilling out and reading page after page. On the other hand, the Kindle has an awkward navigation interface. While menus are displayed clearly on the screen, the method of selecting menu items is tricky: alongside the right-hand edge of the main display is a thin column that acts as a second display. It has a white background, and a scrollable silver cursor that is moved up or down through the use of the device’s scrollwheel. Picking a menu item on the main display involves scrolling the silver cursor to a position parallel to that menu item and pushing the scrollwheel in. This navigation technique creates a disconnect, literally. You don’t really click on a selection so much as you gesture toward it. I got used to this technique quickly, but I didn’t love it. It definitely created a kind of anxiety in me, making me feel the need to speed through menus and get to my destination document quickly. Once there, I could calm down and relax. Books are great on the Kindle. Magazines and newspapers much less so. I found the rendering of photographs, and even illustrations, to be unacceptably crude. For this reason, I expect that reading textbooks on the Kindle may leave students wanting. I found that the original flow and layout of any publication was sacrificed on the Kindle. In effect, browsing a magazine or newspaper was almost impossible. Reading the text of individual articles was enjoyable, but having to read this way made the whole experience much more “a la carte” than cohesive and thematic between articles. I imagine that for academic journals this is ideal, but for consumer publications it imposes a stripped-down, low-fidelity experience that evokes a sense of deprivation. In general, the Kindle is great for reading text. For just about anything else, especially activity that involves exploratory browsing, meandering and short-attention-span reading, it presents a real barrier to entry and adoption. Avid book readers will enjoy the Kindle (if they’re not already). It’s a great device for losing oneself in a book over long sittings. Multitaskers who are more interested in periodicals, be they online or off, will like it much less, as they will find compromise, and even sacrifice, to be palpable.   iPad The iPad is a very different device from the Kindle. While the Kindle is oriented to pages of text, the iPad orbits around applications and their interfaces. Be it the pinch and zoom experience in the browser, the rich media features that augment content on news and weather sites, or the ability to interact with social networking services like Twitter, the iPad is versatile. While it shares a slate-like form factor with the Kindle, it’s effectively an elegant personal computer. One of its many features is the iBook application and integration of the iBookstore. But it’s a multi-purpose device. That turns out to be good and bad, depending on what you’re reading. The iBookstore is great for browsing. It’s color, rich animation-laden user interface make it possible to shop for books, rather than merely search and acquire them. Unfortunately, its selection is rather sparse at the moment. If you’re looking for a New York Times bestseller, or other popular titles, you should be OK. If you want to read something more specialized, it’s much harder. Unlike the awkward navigation interface of the Kindle, the iPad offers a nearly flawless touch-screen interface that seduces the user into tinkering and kibitzing every bit as much as the Kindle lulls you into a deep, concentrated read. It’s a dynamic and interactive device, whereas the Kindle is static and passive. The iBook reader is slick and fun. Use the iPad in landscape mode and you can read the book in 2-up (left/right 2-page) display; use it in portrait mode and you can read one page at a time. Rather than clicking a hardware button to turn pages, you simply drag and wipe from right-to-left to flip the single or right-hand page. The page actually travels through an animated path as it would in a physical book. The intuitiveness of the interface is uncanny. The reader also accommodates saving of bookmarks, searching of the text, and the ability to highlight a word and look it up in a dictionary. Pages display brightly and clearly. They’re easy to read. But the backlight and the glare made me less comfortable than I was with the Kindle. The knowledge that completely different applications (including the Web and email and Twitter) were just a few taps away made me antsy and very tempted to task-switch. The knowledge that battery life is an issue created subtle discomfort. If the Kindle makes you feel like you’re in a library reading room, then the iPad makes you feel, at best, like you’re under fluorescent lights at a Barnes and Noble or Borders store. If you’re lucky, you’d be on a couch or at a reading table in the store, but you might also be standing up, in the aisles. Clearly, I didn’t find this conducive to focused and sustained reading. But that may have more to do with my own tendency to read periodicals far more than books, and my neurotic . And, truth be known, the book reading experience, when not explicitly compared to Kindle’s, was still pleasant. It is also important to point out that Kindle Store-sourced books can be read on the iPad through a Kindle reader application, from Amazon, specific to the device. This offered a less rich experience than the iBooks reader, but it was completely adequate. Despite the Kindle brand of the reader, however, it offered little in terms of simulating the reading experience on its namesake device. When it comes to periodicals, the iPad wins hands down. Magazines, even if merely scanned images of their print editions, read on the iPad in a way that felt similar to reading hard copy. The full color display, touch navigation and even the ability to render advertisements in their full glory makes the iPad a great way to read through any piece of work that is measured in pages, rather than chapters. There are many ways to get magazines and newspapers onto the iPad, including the Zinio reader, and publication-specific applications like the Wall Street Journal’s and Popular Science’s. The New York Times’ free Editors’ Choice application offers a Times Reader-like interface to a subset of the Gray Lady’s daily content. The completely Web-based but iPad-optimized Times Skimmer site (at www.nytimes.com/timesskimmer) works well too. Even conventional Web sites themselves can be read much like magazines, given the iPad’s ability to zoom in on the text and crop out advertisements on the margins. While the Kindle does have an experimental Web browser, it reminded me a lot of early mobile phone browsers, only in a larger size. For text-heavy sites with simple layout, it works fine. For just about anything else, it becomes more trouble than it’s worth. And given the way magazine articles make me think of things I want to look up online, I think that’s a real liability for the Kindle.   Summing Up What I came to realize is that the Kindle isn’t so much a computer or even an Internet device as it is a printer. While it doesn’t use physical paper, it still renders its content a page at a time, just like a laser printer does, and its output appears strikingly similar. You can read the rendered text, but you can’t interact with it in any way. That’s why the navigation requires a separate cursor display area. And because of the page-oriented rendering behavior, turning pages causes a flash on the display and requires a sometimes long pause before the next page is rendered. The good side of this is that once the page is generated, no battery power is required to display it. That makes for great battery life, optimal viewing under most lighting conditions (as long as there is some light) and low-eyestrain text-centric display of content. The Kindle is highly portable, has an excellent selection in its store and is refreshingly distraction-free. All of this is ideal for reading books. And iPad doesn’t offer any of it. What iPad does offer is versatility, variety, richness and luxury. It’s flush with accoutrements even if it’s low on focused, sustained text display. That makes it inferior to the Kindle for book reading. But that also makes it better than the Kindle for almost everything else. As such, and given that its book reading experience is still decent (even if not superior), I think the iPad will give Kindle a run for its money. True book lovers, and people on a budget, will want the Kindle. People with a robust amount of discretionary income may want both devices. Everyone else who is interested in a slate form factor e-reading device, especially if they also wish to have leisure-friendly Internet access, will likely choose the iPad exclusively. One thing is for sure: iPad has reduced Kindle’s market, and may have shifted its mass market potential to a mere niche play. If Amazon is smart, it will improve its iPad-based Kindle reader app significantly. It can then leverage the iPad channel as a significant market for the Kindle Store. After all, selling the eBooks themselves is what Amazon should care most about.

    Read the article

  • License Check before executing

    - by jaklucky
    Hi, We have an application (written in C# on .NET Framework 3.5) that is licensed using our custom licensing mechanism. In the current implementation, in each method we first check for if the machine has valid license or not. To me, it is little bit awkward. Is there any way to let the runtime check for the license before creating the object or excuting a method? Will writing a custom attribute solves this problem? Any ideas or solutions are greatly appreciated. Thank you, Suresh

    Read the article

  • WPF RichTextBox - Formatting of typed text

    - by Alan Spark
    I am applying formatting to selected tokens in a WPF RichTextBox. To do this I get a TextRange that encompasses the token that I would like to highlight. I will then change the color of the text like this: textRange.ApplyPropertyValue(TextElement.ForegroundProperty, Brushes.Blue); This is happening on the TextChanged event of my RichTextBox. The formatting is applied as expected, but continuing to type text will result in the new text inheriting the formatting that has already been applied to the adjacent word. I would like the formatting of any new text to use the default formatting options defined in the RichTextBox properties. Is this possible? Alternatively I could highlight all tokens that I don't want be blue with the default formatting options but this feels awkward to me.

    Read the article

  • Knowledge base web app -- need a demo mode

    - by Smandoli
    I was contracted to build an on-line knowledge base that searches and cross-references many thousands of replacement parts for a niche industry. My client furnishes this app to his customers on a subscription basis. It uses MySQL and PHP and it works great. I want to deploy it in "demo mode" to sell my skills. I want the user to see the functions, but I have to guard the data for my client. My first idea was to obfuscate the results. That's at cross-purposes with showing how well it searches. I'm considering a limit on how many searches you can perform, but that's awkward too as someone could visit every day and get more answers than we would prefer. Other posts I've found are about letting people interact with an app, but without the challenge of protecting a big knowledge base. Can you suggest an approach? (Note, I put the tag obfuscation, but not sure it applies because java code obfuscation seems to be unrelated.)

    Read the article

  • embed google map in wpf control

    - by Dave Turvey
    Hi, I am trying to create a wpf control that will display a map image using google maps. I want to be able to centre the map on a longitude and latitude specified by the application. Ideally, the control will then allow the user to move a map marker and store the latitude/longitude of the marker in the application. The only way I can think of doing this is to use a WebBrowser control and create a HTML string at runtime that shows a map of the desired location. This seems like an awkward solution and won't allow me to easily retrieve the marker location. Does anyone know of a better way to accomplish this?

    Read the article

  • Using Add-on SDK to add toolbar buttons? Integrating XUL and Add-on SDK for Firefox Add-ons?

    - by Salami
    I have already coded most of a Firefox add-on using the Add-on SDK API. I am now discovering that Add-on SDK might not be powerful enough for my purposes. I need two things: A drop down button in the toolbar next to the location bar. To modify the add-ons manager in firefox It is truly disappointing, but I don't believe either of these is possible with the Add-on SDK. First of all, I understand there is a widget module in the Add-on SDK API. But this only allows me to add a simple icon or label to the awkward add-on bar. What if I need to add a nicer button like the one next to the location bar for Firebug or Greasemonkey? As for modifying the add-ons manager in firefox, I have tried Nickolay Ponomarev's XUL with the Add-on SDK without any success whatsoever. If anyone knows how to get this working and can point me in the right direction that would be extremely helpful (cfx init --template xul doesn't do anything the regular SDK does when I try it)

    Read the article

  • How to manipulate and print a chart in MS Excel from AppleScript?

    - by Stu Thompson
    With an existing chart in a MS Excel for Mac 2008, in AppleScript, I am trying to do two things: Rotate a 3D chart 1° Save the chart as a image (png) From what I've found on the Intertubes, it seems possible. But AppleScript's awkward verbosity and the lack of non-trivial MS Excel AppleScript examples on the web are too much for me to overcome. Just for the saving part, this is what I have so far: tell application "Microsoft Excel" activate object worksheet "iozone-16" set cht to chart object 1 of active sheet tell cht #save as chart object [picture type enumeration] [file name Unicode text] #Argh!!! end tell end tell The 'rotate 1°' task seems to involve "internal objects", but that is as far as I've gotten.

    Read the article

  • How to add parameters to HttpURLConnection using POST

    - by Michal Švácha
    I am trying to do POST with HttpURLConnection(I need to use it this way, can't use HttpPost) and I'd like to add parameters to that connection such as post.setEntity(new UrlEncodedFormEntity(nvp)); where nvp = new ArrayList<NameValuePair>(); having some data stored in. I can't find a way how to add this ArrayList to my HttpURLConnection which is here: HttpsURLConnection https = (HttpsURLConnection) url.openConnection(); https.setHostnameVerifier(DO_NOT_VERIFY); http = https; http.setRequestMethod("POST"); http.setDoInput(true); http.setDoOutput(true); the reason for that awkward https and http combination is the need for not verifying the certificate. That is not a problem, though, it posts. But I need it to post with arguments. Any ideas? Thanks a lot!

    Read the article

  • Multilingual support using gettext with codeigniter, best practice?

    - by tobefound
    I know how to create .po files and how to generate .mo files and then use them for translation on my Codeigniter powered site. However, I'm not quite sure on how to change language from the site GUI. I want to stick to codeigniter's default url calling schema: www.domain.com/controllername/method/param1/param2. Calling the server like this is a no-brainer: www.domain.com/controllername?lang=en Doing that for every controller using the default url schema, requires me to implement the same method in every controller, just to pass the lang parameter to the setlocale() function and then bind to my .po domain name. Feels awkward... ANy ideas how you guys work with gettext in codeigniter? And yes, I do want to work with gettext.

    Read the article

  • ColdFusion structs Direct Assignment vs object literal notation.

    - by Tom Hubbard
    The newer versions of ColdFusion (I believe CF 8 and 9) allow you to create structs with object literal notation similar to JSON. My question is, are there specific benefits (execution efficiency maybe) to using object literal notation over individual assignments for data that is essentially static? For example: With individual assignments you would do something like this: var user = {}; user.Fname = "MyFirstnam"; user.Lname = "MyLastName"; user.titles = []; ArrayAppend(user.titles,'Mr'); ArrayAppend(user.titles,'Dr.'); Whereas with object literals you would do something like. var user = {Fname = "MyFirstnam", Lname = "MyLastName", titles = ['Mr','Dr']}; Now this limited example is admittedly simple, but if titles was an array of structures (Say an array of addresses), the literal notation becomes awkward to work with.

    Read the article

  • Can I have a shell alias evaluate a history substitution command?

    - by Brandon
    I'm trying to write an alias for cd !!:1, which takes the 2nd word of the previous command, and changes to the directory of that name. For instance, if I type rails new_project cd !!:1 the second line will cd into the "new_project" directory. Since !!:1 is awkward to type (even though it's short, it requires three SHIFTed keys, on opposite sides of of the keyboard, and then an unSHIFTed version of the key that was typed twice SHIFTed), I want to just type something like cd- but since the !!:1 is evaluated on the command line, I (OBVIOUSLY) can't just do alias cd-=!!:1 or I'd be saving an alias that contained "new_project" hard-coded into it. So I tried alias cd-='!!:1' The problem with this is that the !!:1 is NEVER evaluated, and I get a message that no directory named !!:1 exists. How can I make an alias where the history substitution is evaluated AT THE TIME I ISSUE THE ALIAS COMMAND, not when I define the alias, and not never? (I've tried this in both bash and zsh, and get the same results in both.)

    Read the article

  • Dropdown Menus In Drupal?

    - by Wade D Ouellet
    Hi, I have my Drupal site here so far: selkirk.treethink.net Each Primary Link at the top has a bunch of other primary links under it (sub links) I need to display these sub links when you hover over the parent primary link in a dropdown menu. Everything is in the primary links but there are parents (what you see at the top of the demo) and sub links (what should be in the dropdown). I'm not sure if I set up these menus wrong though...Drupal is a little awkward for me. I did download this module but I am not sure how to get it going to automatically dropdown a primary link's submenu items when rolled over: http://drupal.org/project/jquery_dropdown Thanks, Wade

    Read the article

  • Python: Decent config file format

    - by miracle2k
    I'd like to use a configuration file format which supports key value pairs and nestable, repeatable structures, and which is as light on syntax as possible. I'm imagining something along the lines of: cachedir = /var/cache mail_to = [email protected] job { name = my-media frequency = 1 day source { from = /home/michael/Images source { } source { } } job { } I'd be happy with something using significant-whitespace as well. JSON requires too many explicit syntax rules (quoting, commas, etc.). YAML is actually pretty good, but would require the jobs to be defined as a YAML list, which I find slightly awkward to use.

    Read the article

  • Branch by abstraction: Are there "examples" of how it can be done?

    - by Philipp Keller
    Having read Martin Fowlers "Feature Branch" and Flickrs "Flipping Out" (http://www.liip.to/flippingout) I guess there are a few guys out there who do: all (or most) development on Trunk release Trunk regularly (assuming updating your web site) not-yet-approved or not-yet-finished features should not be visible/have no impact on the regular user I've got 2 questions: granted - Flickr's article seems to work for "frontend code". But how is it cleaned up? Don't the ifs pile up? how does this work for the more "backend part"? Thinking of database changes, or model refactoring. Working with ifs doesn't seem to work - and copy-pasting classes for small adaptions also seems awkward. Are there any articles out there answering these 2 questions?

    Read the article

  • Why C# calls different overloaded method for different values of same type?

    - by Fabio Veronez
    Hello all, I have one doubt concerning c# method overloading call resolution. Let's suppose I have the following C# code: enum MyEnum { Value1, Value2 } public void test() { method(0); // this calls method(MyEnum) method(1); // this calls method(object) } public void method(object o) { } public void method(MyEnum e) { } Note that I know how to make it work but I would like to know why for one value of int (0) it calls one method and for another (1) it calls another. It sounds awkward since both values have the same type (int) but they are "linked" for different methods. Ps.: This is my first question here, i'm sorry if I made something wrong. =P

    Read the article

  • JUnit - stop it from exiting on finish?

    - by waitinforatrain
    Hi guys, Quick JUnit question. I'm running some unit tests that involve starting up the GUI and doing a load of stuff. I would like to see the results after the test to confirm it visually. However, it gets to the end of the code and exits, as it should. If I want to override this, I put a breakpoint on the last line of the test. This is pretty awkward though. Is there some option to stop it from exiting?

    Read the article

  • Generic type in generic collection

    - by Brian Triplett
    I have generic type that looks like: public class GenericClass<T, U> where T : IComparable<T> { // Class definition here } I then have a collection of these instances. What is the cleanest way to pass through the type constraints? public class GenericCollection<V> where V : GenericClass<T, U> // This won't compile { private GenericClass<T, U>[] entries; public V this[index] { get{ return this.entries[index]; } } } Is there perhaps a better way to design this? I think that specifying GenericCollection<T, U, V> where V : GenericClass<T, U> seems awkward. Might be my only option though....

    Read the article

< Previous Page | 2 3 4 5 6 7 8 9 10 11 12 13  | Next Page >