Search Results

Search found 2579 results on 104 pages for 'mike peshka'.

Page 55/104 | < Previous Page | 51 52 53 54 55 56 57 58 59 60 61 62  | Next Page >

  • How do I get apache RewriteRule working correctly for a subdomain?

    - by mike
    I just setup a subdomain with the following RewriteCond: RewriteCond $1 !^search.php$ RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^/?([^/]+)$ search.php?q=$1 [L,NS] I'm using the same rewrite condition on my main domain and it works perfectly. However, when I set it up on the subdomain, it simply outputs "index.php" when going to http://sub.domain.com Every page on the subdomain outputs the page name in the body instead of processing the code, except for the search page, which appears to be working correctly. What can I do to correct this issue?

    Read the article

  • display of umlauts in firefox

    - by Mike D
    I was doing some web searching and found some strange things involving umlauts. For example if you do a google or yahoo search for the word "nther" you are likely to find things like G&#xfc;nther which I take to be Gunther with an umlaut over the u. Now my question is what if anything can I do to cause these characters to be properly displayed by Firefox under windows XP? An amazing thing is that I had to introduce spaces in the G & # etc string otherwise it was properly displayed here as u with umlaut!

    Read the article

  • Processing incoming email

    - by Mike Schots
    How do I programmatically read an incoming email with .NET. I need a method to take the content of email message (in this case XML) on a POP server and read it into my application. Ideally this could be solved by: .NET code that I can run as a background task on my webserver to process the email. A service that can POST the contents of the email to my webserver. Although I'm open to other options. EDIT: Copied from the "non-answer": Currently, we're looking at using the email accounts our hosting company provides. Our own mail server could potentially be an option, but its something the we'd need to contact the host about.

    Read the article

  • Is yield break equivalent to returning Enumerable<T>.Empty from a method returning IEnumerable<T>

    - by Mike Two
    These two methods appear to behave the same to me public IEnumerable<string> GetNothing() { return Enumerable.Empty<string>(); } public IEnumerable<string> GetLessThanNothing() { yield break; } I've profiled each in test scenarios and I don't see a meaningful difference in speed, but the yield break version is slightly faster. Are there any reasons to use one over the other? Is one easier to read than the other? Is there a behavior difference that would matter to a caller?

    Read the article

  • Decimal Value is Zero when it should be 0.0x

    - by Mike Wills
    If this was previously talked about, I'm sorry, I had a hard time searching on this. I am calculating a depreciation rate. One portion of our calculation is 1/life in months. My table stores this data in a decimal field. I tried test = 1 / estimatedLife; but the result of the calculation of test (which is defined as a decimal) is 0. Say the estimated life is 36 months. So 1/36 should equal 0.02777778. Any thoughts of what I am doing wrong? BTW, I changed the test to a double and had the same result.

    Read the article

  • Is there a good charting library for iPhone?

    - by Mike Akers
    I have a need to render and display charts (bar charts for now, but more types may be needed later) in an iPhone app I'm working on. I've done some looking around and it doesn't look like there are any really good, mature charting libraries for iPhone yet. I've also looked for something written for Cocoa on the Mac that can be adapted, but haven't found anything great yet. Anybody dealt with this before? Any recommendations? I did find Core Plot, but it seems to be in the early stages of development. Edit to add some details of requirements (as they currently stand ;) ) Bar Charts Horizontal bar charts Double stacked bar charts Axis labels (including rotated 90 degrees on the y axis) Labels above each bar on the chart Shaded or custom backgrounds

    Read the article

  • Overly accessible and incredibly resource hungry relationships between business objects. How can I f

    - by Mike
    Hi, Firstly, This might seem like a long question. I don't think it is... The code is just an overview of what im currently doing. It doesn't feel right, so I am looking for constructive criticism and warnings for pitfalls and suggestions of what I can do. I have a database with business objects. I need to access properties of parent objects. I need to maintain some sort of state through business objects. If you look at the classes, I don't think that the access modifiers are right. I don't think its structured very well. Most of the relationships are modelled with public properties. SubAccount.Account.User.ID <-- all of those are public.. Is there a better way to model a relationship between classes than this so its not so "public"? The other part of this question is about resources: If I was to make a User.GetUserList() function that returns a List, and I had 9000 users, when I call the GetUsers method, it will make 9000 User objects and inside that it will make 9000 new AccountCollection objects. What can I do to make this project not so resource hungry? Please find the code below and rip it to shreds. public class User { public string ID {get;set;} public string FirstName {get; set;} public string LastName {get; set;} public string PhoneNo {get; set;} public AccountCollection accounts {get; set;} public User { accounts = new AccountCollection(this); } public static List<Users> GetUsers() { return Data.GetUsers(); } } public AccountCollection : IEnumerable<Account> { private User user; public AccountCollection(User user) { this.user = user; } public IEnumerable<Account> GetEnumerator() { return Data.GetAccounts(user); } } public class Account { public User User {get; set;} //This is public so that the subaccount can access its Account's User's ID public int ID; public string Name; public Account(User user) { this.user = user; } } public SubAccountCollection : IEnumerable<SubAccount> { public Account account {get; set;} public SubAccountCollection(Account account) { this.account = account; } public IEnumerable<SubAccount> GetEnumerator() { return Data.GetSubAccounts(account); } } public class SubAccount { public Account account {get; set;} //this is public so that my Data class can access the account, to get the account's user's ID. public SubAccount(Account account) { this.account = account; } public Report GenerateReport() { Data.GetReport(this); } } public static class Data { public static List<Account> GetSubAccounts(Account account) { using (var dc = new databaseDataContext()) { List<SubAccount> query = (from a in dc.Accounts where a.UserID == account.User.ID //this is getting the account's user's ID select new SubAccount(account) { ID = a.ID, Name = a.Name, }).ToList(); } } public static List<Account> GetAccounts(User user) { using (var dc = new databaseDataContext()) { List<Account> query = (from a in dc.Accounts where a.UserID == User.ID //this is getting the user's ID select new Account(user) { ID = a.ID, Name = a.Name, }).ToList(); } } public static Report GetReport(SubAccount subAccount) { Report report = new Report(); //database access code here //need to get the user id of the subaccount's account for data querying. //i've got the subaccount, but how should i get the user id. //i would imagine something like this: int accountID = subAccount.Account.User.ID; //but this would require the subaccount's Account property to be public. //i do not want this to be accessible from my other project (UI). //reading up on internal seems to do the trick, but within my code it still feels //public. I could restrict the property to read, and only private set. return report; } public static List<User> GetUsers() { using (var dc = new databaseDataContext()) { var query = (from u in dc.Users select new User { ID = u.ID, FirstName = u.FirstName, LastName = u.LastName, PhoneNo = u.PhoneNo }).ToList(); return query; } } }

    Read the article

  • TinyMCE or HTML5's contentEditable attribute?

    - by Mike
    I have always hated wysiwyg editors but most of the applications I develop they are necessary for our clients to edit their content. After trying out a few different ones I seemed to like tinyMCE the best. Although powerful and seems to generate fairly good HTML it is not without its issues. Recently I have been thinking about creating a custom wysiwyg that suits my needs perfectly taking advantage of the contentEditable attribute. Is this HTML5 feature ready? Will I have many cross browser issues? What are its limitations? I guess my question finally boils down to; Will it be worth throwing in the towel on 3rd party wysiwygs and moving to contentEditable regions?

    Read the article

  • How do you debug a windows service that is being installed?

    - by Mike Pateras
    I know how to attach a debugger to a windows service, but I can't seem to get attached to one that's being installed and started by a windows installer. I've tried: Setting a Thread.Sleep(TimeSpan.FromSeconds(30)); at the beginning of the on-start, but when I try to attach in Visual Studio, the name of the service does not appear as an option. This normally works, the service's name shows up in the list, but when using the installer it does not. Setting a Debugger.Break and Debugger.Launch. Neither really do anything. What can I do to debug my service?

    Read the article

  • Convert query from native SQL to LINQ request

    - by mike
    Please, help me. How i can translate this SQL query to LINQ request? SELECT TOP (1) PERCENT DATEDIFF(DAY, dbo.PO.ORDER_DATE, GETDATE()) AS Age FROM dbo.ITEMS INNER JOIN dbo.X_PO ON dbo.ITEMS.ITEMNO = dbo.X_PO.ITEM_CODE INNER JOIN dbo.PO ON dbo.X_PO.ORDER_NO = dbo.PO.DOC_NO AND dbo.X_PO.STATUS = dbo.PO.STATUS WHERE (dbo.ITEMS.ITEMNO = 'MBIN001') AND (dbo.X_PO.STATUS = 3) ORDER BY Age

    Read the article

  • Outlook 2010 Retrieving and restricting appointments programmatically causing recurrences to be incl

    - by Mike Dearing
    I wrote a winforms app that uses Microsoft.Office.Interop.Outlook to retrieve and restrict appointments based upon the date range entered by a user. This worked fine with Outlook 2007 installed, however now that some users have updated to Outlook 2010 the appointment retrieval is pulling back incorrect appointments along with the correct ones falling within the specified date range. The additional incorrect appointments being retrieved always appear to be recurring appointments. I was wondering if this is a known bug and if so what exactly is happening that is causing these additional recurring appointments to come in? I'd rather not have to throw in a workaround where I step through the items after they have been restricted and remove the extra ones, when this functionality works fine with 2007. Note: I've not recompiled or updated any code when experiencing this issue, just running the old program. This is the spot in my code where appointments are being restricted. This is similar to the way advised in the following msdn link: http://msdn.microsoft.com/en-us/library/bb611267.aspx Microsoft.Office.Interop.Outlook.Items outlookItems = outlookMapiFolder.Items.Restrict( "[Start] >= '" + outlookImport.startDay.ToString("g") + "' AND [Start] <= '" + outlookImport.endDay.ToString("g") + "'"); outlookItems.Sort("[Start]", Type.Missing); outlookItems.IncludeRecurrences = true;

    Read the article

  • How to install a Linux Rails gem on Windows

    - by Mike Sutton
    I need to upload vendorize a gem which is causing problems at my host - in this case nokogiri. My host is using linux, my development system is windows. The gem contains binaries and so my local gem downloads the win32 binaries. Is there any way I can get gem to download the linux binaries, so I can vendorize and upload them?

    Read the article

  • Is it possible to have mspec & NUnit tests in a single project

    - by Mike Scott
    I've got a unit test project using NUnit. When I add the mspec (machine.specifications) assembly to the references, both ReSharper and TestDriven.Net stop running the NUnit tests and only run the mspec tests. Is there a way or setting that allows both NUnit & mspec tests to co-exist and run in the same project using R# & TD.Net test runners?

    Read the article

  • Python SQLite FTS3 alternatives?

    - by Mike Cialowicz
    Are there any good alternatives to SQLite + FTS3 for python? I'm iterating over a series of text documents, and would like to categorize them according to some text queries. For example, I might want to know if a document mentions the words "rating" or "upgraded" within three words of "buy." The FTS3 syntax for this query is the following: (rating OR upgraded) NEAR/3 buy That's all well and good, but if I use FTS3, this operation seems rather expensive. The process goes something like this: # create an SQLite3 db in memory conn = sqlite3.connect(':memory:') c = conn.cursor() c.execute('CREATE VIRTUAL TABLE fts USING FTS3(content TEXT)') conn.commit() Then, for each document, do something like this: #insert the document text into the fts table, so I can run a query c.execute('insert into fts(content) values (?)', content) conn.commit() # execute my FTS query here, look at the results, etc # remove the document text from the fts table before working on the next document c.execute('delete from fts') conn.commit() This seems rather expensive to me. The other problem I have with SQLite FTS is that it doesn't appear to work with Python 2.5.4. The 'CREATE VIRTUAL TABLE' syntax is unrecognized. This means that I'd have to upgrade to Python 2.6, which means re-testing numerous existing scripts and programs to make sure they work under 2.6. Is there a better way? Perhaps a different library? Something faster? Thank you.

    Read the article

  • How to open a nested child PreferenceScreen in Android.

    - by Mike
    Hello, I have a PreferenceScreen that is defined in XML that serves all the preferences for my application. This PreferenceScreen also has a child PreferenceScreen nested within it. My implementing class is called PreferencesActivity. I know I can open the main Preferences window via startActivity(new Intent(this, PreferencesActivity.class)); but how do I go about opening the child PreferenceScreen via an Intent?

    Read the article

  • Accessing Oracle 6i and 9i/10g Databases using C#

    - by Mike M
    Hi all, I am making two build files using NAnt. The first aims to automatically compile Oracle 6i forms and reports and the second aims to compile Oracle 9i/10g forms and reports. Within the NAnt task is a C# script which prompts the developer for database credentials (username, password, database) in order to compile the forms and reports. I want to then run these credentials against the relevant database to ensure the credentials entered are correct and, if they are not, prompt the user to re-enter their credentials. My script currently looks as follows: class GetInput { public static void ScriptMain(Project project) { Console.Clear(); Console.WriteLine("==================================================================="); Console.WriteLine("Welcome to the Compile and Deploy Oracle Forms and Reports Facility"); Console.WriteLine("==================================================================="); Console.WriteLine(); Console.WriteLine("Please enter the acronym of the project to work on from the following list:"); Console.WriteLine(); Console.WriteLine("--------"); Console.WriteLine("- BCS"); Console.WriteLine("- COPEN"); Console.WriteLine("- FCDD"); Console.WriteLine("--------"); Console.WriteLine(); Console.Write("Selection: "); project.Properties["project.type"] = Console.ReadLine(); Console.WriteLine(); Console.Write("Please enter username: "); string username = Console.ReadLine(); project.Properties["username"] = username; string password = ReturnPassword(); project.Properties["password"] = password Console.WriteLine(); Console.Write("Please enter database: "); string database = Console.ReadLine(); project.Properties["database"] = database Console.WriteLine(); //Call method to verify user credentials Console.WriteLine(); Console.WriteLine("Compiling files..."; } public static string ReturnPassword() { Console.Write("Please enter password: "); string password = ""; ConsoleKeyInfo nextKey = Console.ReadKey(true); while (nextKey.Key != ConsoleKey.Enter) { if (nextKey.Key == ConsoleKey.Backspace) { if (password.Length > 0) { password = password.Substring(0, password.Length - 1); Console.Write(nextKey.KeyChar); Console.Write(" "); Console.Write(nextKey.KeyChar); } } else { password += nextKey.KeyChar; Console.Write("*"); } nextKey = Console.ReadKey(true); } return password; } } Having done a bit of research, I find that you can connect to Oracle databases using the System.Data.OracleClient namespace clicky. However, as mentioned in the link, Microsoft is discontinuing support for this so it is not a desireable solution. I have also fonud that Oracle provides its own classes for connecting to Oracle databases clicky. However, this only seems to support connecting to Oracle 9 or newer databases (clicky) so it is not feasible solution as I also need to connect to Oracle 6i databases. I could achieve this by calling a bat script from within the C# script, but I would much prefer to have a single build file for simplicity. Ideally, I would like to run a series of commands such as is contained in the following .bat script: rem -- Set Database SID -- set ORACLE_SID=%DBSID% sqlplus -s %nameofuser%/%password%@%dbsid% set cmdsep on set cmdsep '"'; --" set term on set echo off set heading off select '========================================' || CHR(10) || 'Have checked and found both Password and ' || chr(10) || 'Database Identifier are valid, continuing ...' || CHR(10) || '========================================' from dual; exit; This requires me to set the environment variable of ORACLE_SID and then run sqlplus in silent mode (-s) followed by a series of sql set commands (set x), the actual select statement and an exit command. Can I achieve this within a c# script without calling a bat script, or am I forced to call a bat script? Thanks in advance!

    Read the article

  • Most efficient way to store list structure in XML

    - by Mike
    Starting a new project and was planning on storing all of my web content in XML. I do not have access to a database so this seemed like the next best thing. One thing I'm struggling with is how to structure the XML for links (which will later be transformed using XSLT). It needs to be fairly flexible as well. Below is what I started with, but I'm starting to question it. <links> <link> <url>http://google.com</url> <description>Google</description> <link> <link> <url>http://yahoo.com</url> <description>Yahoo</description> <links> <url>http://yahoo.com/search</url> <description>Search</description> </link> <link> </links> That should get transformed into Google Yahoo Search Perhaps something like this might work better. <links> <link href="http://google.com">Google</link> <link href="http://yahoo.com">Yahoo <link href="http://yahoo.com/search">Search</link> </link> </links> Does anyone perhaps have a link that talks about structuring web content properly in XML? Thank you. :)

    Read the article

  • C# text creation issue

    - by Mike
    This is whats going on. I have a huge text file that is suppose to be 1 line per entry. The issue is sometimes the line is broken with a new line. I edit this entire file and wherever the file doesn't begin with ("\"A) i need to append the current line to the previous line ( replacing \n with " "). Everything I come up with keeps appending the line to a new line. Any help is appricated... CODE: public void step1a() { string begins = ("\"A"); string betaFilePath = @"C:\ext.txt"; string[] lines = File.ReadAllLines(betaFilePath); foreach (string line in lines) { if (line.StartsWith(begins)) { File.AppendAllText(@"C:\xt2.txt",line); File.AppendAllText(@"C:\xt2.txt", "\n"); } else { string line2 = line.Replace(Environment.NewLine, " "); File.AppendAllText(@"C:\xt2.txt",line2); } } } Example: Orig: "\"A"Hero|apple|orange|for the fun of this "\"A"Hero|apple|mango|lots of fun always "\"A"Her|apple|fruit|no pain is the way "\"A"Hero|love|stackoverflowpeople|more fun Resulting: "\"A"Hero|apple|orange|for the fun of this "\"A"Hero|apple|mango|lots of fun always "\"A"Her|apple|fruit|no pain is the way "\"A"Hero|love|stackoverflowpeople|more fun

    Read the article

  • iphone - using NSInvocation: constant value

    - by Mike
    I am dealing with an old iPhone OS 2.x project and I want to keep compatibility, while designing for 3.x. I am using NSInvocation, is a code like this NSInvocation* invoc = [NSInvocation invocationWithMethodSignature: [cell methodSignatureForSelector: @selector(initWithStyle:reuseIdentifier:)]]; [invoc setTarget:cell]; [invoc setSelector:@selector(initWithStyle:reuseIdentifier:)]; int arg2 = UITableViewCellStyleDefault; //???? [invoc setArgument:&arg2 atIndex:2]; [invoc setArgument:&identificadorNormal atIndex:3]; [invoc invoke]; to call 3.0 APIs on 2.0. I am having a problem on the line I marked with question marks. The problem there is that I am trying to assing to arg2, a constant that has not been defined in OS 2.0. As everything with NSInvocation is to do stuff indirectly to avoid compiler errors, how do I set this constant to a variable in an indirect way? Some sort of performSelector "assign value to variable"... is that possible? thanks for any help.

    Read the article

  • filterSecurityInterceptor and metadatasource implementation spring-security

    - by Mike
    Hi! I created a class that implements the FilterInvocationSecurityMetadataSource interface. I implemented it like this: public List<ConfigAttribute> getAttributes(Object object) { FilterInvocation fi = (FilterInvocation) object; Object principal = SecurityContextHolder.getContext().getAuthentication().getPrincipal(); Long companyId = ((ExtenededUser) principal).getCompany().getId(); String url = fi.getRequestUrl(); // String httpMethod = fi.getRequest().getMethod(); List<ConfigAttribute> attributes = new ArrayList<ConfigAttribute>(); FilterSecurityService service = (FilterSecurityService) SpringBeanFinder.findBean("filterSecurityService"); Collection<Role> roles = service.getRoles(companyId); for (Role role : roles) { for (View view : role.getViews()) { if (view.getUrl().equalsIgnoreCase(url)) attributes.add(new SecurityConfig(role.getName() + "_" + role.getCompany().getName())); } } return attributes; } when I debug my application I see it reaches this class, it only reaches getAllConfigAttributes method, that is empty as I said, and return null. after that it prints this warning: Could not validate configuration attributes as the SecurityMetadataSource did not return any attributes from getAllConfigAttributes(). My aplicationContext- security is like this: <beans:bean id="filterChainProxy" class="org.springframework.security.web.FilterChainProxy"> <filter-chain-map path-type="ant"> <filter-chain filters="sif,filterSecurityInterceptor" pattern="/**" /> </filter-chain-map> </beans:bean> <beans:bean id="filterSecurityInterceptor" class="org.springframework.security.web.access.intercept.FilterSecurityInterceptor"> <beans:property name="authenticationManager" ref="authenticationManager" /> <beans:property name="accessDecisionManager" ref="accessDecisionManager" /> <beans:property name="securityMetadataSource" ref="filterSecurityMetadataSource" /> </beans:bean> <beans:bean id="filterSecurityMetadataSource" class="com.mycompany.filter.FilterSecurityMetadataSource"> </beans:bean> what could be the problem?

    Read the article

< Previous Page | 51 52 53 54 55 56 57 58 59 60 61 62  | Next Page >