Is it permissible to take false oath on Quran to save self honour/ self respect?

Question: I am aware that taking a false oath by Quran is considered a major grave sin and should be avoided at all costs. However, in dire circumstances, is it permissible for a person to take a false oath on the Quran to preserve his/her honour and the honour of his/ her family for a mistake that He/ She made in the past? Meaning if a person was to take a false oath saying He/She was not involved with anyone in the Past (a past mistake which He/she has sincerely repented for), would that be forgiven?
Comment: You can take an oath on Allah only, not Qur'an, because he is the witness over everything, not Qur'an. What ever be the reason.
Answer: assalaam u-alaikum
look, if you have the time to do so, make Istikhaara, asking Allah if you should or shouldnt lie, as Allah knows best, and whatever you see and determine to be the right thing to do, do it if it is decreed from Allah the All mighty. the reaos hwy i say Istikhaara is because judging by the situation, it is a pretty big one, and you dont want to lower the status/reputation of yuor family, but at the same time, you dont want to risk taking a false oath, as Allah swt says in the quran:
"Allah does not persecute you for your purposeless (and frivolous) oaths, but takes you to task for your (solemn) oaths which you affirm (deliberately). (If you breach such oaths) the atonement is feeding ten poor persons with an average (quality) food which you serve to your family, or providing them (the poor) with the clothes, or freeing one neck (i.e., a slave). But the one who does not find (all this) shall fast for three days. This is the atonement for your oaths which you affirm (and then break). So, always guard your oaths. It is this way Allah explains most clearly His Revelations to you so that you may become grateful (by obeying His commandments)."(5:89)
also another thing i would like to add is i have heard we shouldnt swear on anything except the name of Allah, so you might want to look into that (i'm not 100% sure though)
Answer: Assalamualaikum brother,
General ruling in islam is that sinning should be avoided always, and you should always conceal your sins. But Scholars mention that because of this principle, one may lie when confronted about past sins [assuming doing so does not entail neglect of another's right, such as not returning stolen money]. Such a lie would not be unlawful.
Yet even when lying is permissible, it would be religiously more precautionary to use misleading words instead of outright lying. [Nahlawi, Durar al-Mubaha]
For example, if asked about a sin in the past that one did commit, one could say, "Alhamdulillah, Allah protected me from that," intending one's sincere repentance after the sin, i.e., that Allah protected me from falling into it again…
And Allah knows the best.
Comment: Please clarify what this means? Is this a yes, it is permissible (False Oath on a Quran)? I know lying is permissible depending on the situation but what about oaths?
Comment: it is Yes. it is permissible..but should be avoided
Answer: big sin and major sin allah himself condemned in the quran. why asking people for this answer it is in the Quran. what believer uses the name of allah purposely to save their self respect for the creation. when all honor comes from allah  not the creation. it is amongst the worst sins one can do  because you are using the name of allah falsely and purposely to mislead another person. no one with good faith does this. sorry but no one with real faith does this purposely. maybe out of accident but no true believer does this action time and time again to save their own honor. never make the people happy with you at the expense of the anger of allah. lies lead to hell fire. the lying that is permissible is lying to reconcile two Muslims who are fighting. a lie that brings one's wife closer in love or husband vice versa. better to say who you  are that way these lies don't come back to bite you later in life. because lies leads to other lies. in order to lie you need other  lies to surround it. as we find from the prophet himself he specifically said lying is a sign of hypocrisy so imagine one who lies using the name of allah to make themselves look good and save their respect. seems like you care more about how the people view you rather than how your lord sees you. this is also a certain way of shirk you have made also.
may allah guide you and show you the reality of himself and his threats and his rewards. ameen


Genuine Student Rule for Tier 4 Applications

Question: Does it hurt a Tier 4 applicant's credibility if their spouse is already a UK resident?
Comment: On what basis is your spouse in the UK? Work? Study?
Answer: No, not exactly. But you must be a genuine student, coming to the UK for the purposes of study, and able to qualify on these grounds alone (as if you weren't married to a UK resident). If you are not a genuine student, and are only coming to join your spouse by another means, the Home Office is quite savy to this, and then your application will get the extra scrutiny it deserves.
Comment: DLR? Could be a while before he is naturalized depending on if there were any periods of overstay before he was granted DLR. And the spirit of the process of ILR > UK Citizenship is that you will make the UK your home and base of life, not just get the passport and leave.
Comment: Thanks for the answer! My husband is on DLR but he qualifies now for an ILR based on long residence. I truly do want to go study AND be with him, the course reflects academic progression to my previous study. Additionally, I am co-funding my studies via an educational loan scheme from a local bank. I don't even want to live in the U.K. After my course ends. We're going to move out as he will have already be naturalized at the end of the period, hopefully.
Comment: In support of @ouflak's comment, see [Become a British citizen](https://www.gov.uk/becoming-a-british-citizen). One of the conditions listed is "you'll continue to live in the UK".


How to select a layer in photoshop?

Question: In Photoshop, if you choose View > Show > Layer Edges, a blue border will appear around the currently-selected layer. Is there a way to make the marquee tool select that exact area? I know I can command-click on the layer thumbnail to select all visible pixels in the layer, but is there a way to quickly get a rectangular selection that matches the layer boundaries, or do I need to manually drag the rectangular marquee tool to match the layer boundary that Photoshop is showing me?
Comment: No inherent way I know of. Certainly no existing command or shortcut. With scripting it should be possible.
Comment: Do you mean selecting the entire canvas? Maybe try cmd + A.
Answer: There is not a "simple" way to do this out of the box, but if you want to select the area to copy you can make an action script with:

Trim (Transparent pixels - same as showing boundaries of the content in the layer)
Select All
Shift+Ctrl+C for merged copy, or just Ctrl+C for content in the current layer.
Revert back to before Trimming.

I created an action for you with these steps. It can be downloaded from here:
http://www.sendspace.com/file/f3nh0n
(remember to perform virus check on files you receive by from strangers such as a me).
Answer: Depending on what you need to do, I do this very often to copy a layer to a new document cropped to bounding pixels:

Alt+Click on the 'eye' of a layer to solo it.
Cmd+A(command or control) to select all
Cmd+Shift+C to copy everything
Cmd+N to create new document, it will automatically create it at
the right size
Cmd+V to paste

Done.
Answer: IIRC, cmd+click on the layer in the layers panel.
Comment: Thanks for answering, but as mentioned in my question, command-clicking in the layer only selects "visible pixels", not the entire rectangle of the layer boundary.
Comment: Sorry, missed that in my haste. That sounds like something for javascript, if this is something you want to do more than once.

How to select a layer in photoshop?


missing pictures/videos from HTC EVO after being encrypted

Question: I have an HTC EVO.  It's been encrypted at work.  Afterwards, all of my pictures/videos are missing from my gallery, everything else is still there.  How do I get them back?
Answer: It is possible (almost certain) that during the encryption process, they low level formatted your SD card which would make recovering your gallery items impossible at this point. They should have allowed you to backup your data before doing the encryption and/or made a backup of the device before they did the encryption. Might I suggest you ask them if they kept a backup before doing the encryption, that would be your only option at this point to get them back. Sorry.


Are there multiple endings to Dark Souls?

Question: Are there multiple endings to Dark Souls? If yes, how many, and how is it determined which ending will be played? Please try to not tell what the ending are, I'm still at the beginning of the game, and I don't want to be spoiled too much.
Answer: There are two, and they are determined by a choice you have to make following the final boss fight.
Answer: You don't need to become a Darkwraith or form a "pact" with Frampt (you dont even need him to place the lordvessel, you can just jump down the hole and warp out),
The ending is only based upon walking away or lighting the bonfire. As to which ending is better: walking away is basically destroying the gods powers and the humans takeover.  Lighting the bonfire kills your character until NG+, NG++, etc.
The walk away ending is better for the humans as they become well, kind of like gods, but lighting the bonfire keeps the gods alive and ruling.
Comment: I would just like to add that both endings are the bad endings. Walking away and plunging the world into "darkness" is just as bad as delaying it if you're a human.
Comment: @ProfPickle If you look at the game's files (on PC) you can see there is a movie called "good_ending" (or something like that). I don't think there is a movie for the other ending.
Answer: Basically to activate the Good (chosen undead)ending you need to saciate the lord vessel with Frampt the worm that awakens when you ring both bells. the second Evil ending is a lot more difficult in my oppinion you have to become a darkwraith by defeating the four kings while still being in possesion of the lordvessel. once the four kings are defeated another worm/ serpent whos name escapes me appears speak with him and saciate the lord vessel afterwards the rest of the game carries on as normal.
in regards to the comments, it penumltimately boils down to lighting the bonfire after the final boss fight. but to discover that you can either leave it or light it you would probably need to find the questlines as stated above because as a new player you would probably not have realised.
Comment: It's debatable which ending is good and which is evil..
Comment: This is not how you determine the ending of the game. The games ending is decided by you either lighting or not lighting the bonfire after fighting the final boss. http://darksouls.wikidot.com/ending
Comment: well what I mentioned is how you activate the choice you have to be darkwraith to activiate and discover that part of the questline or else you'd probably just light it like any other bonfire. and you activate the chosen undead questline when you form a pact with frampt the answer stands as usefull.
Comment: not really as one ends the curse of the undead and the spawn of demons...
Comment: This is not the way to get the secret ending, this is the way to join the Dark Wraiths and get the Red Eye Orb which allows unlimited invasions
Comment: @itcouldevenbeaboat but the other worm also tells you not to satiate the lord vessel and seems to be encouraging you to follow Lord Gwyns path and become a demon yourself that's what I gathered from his dialogs anyway.


What is special in API documentation compared to general technical writing?

Question: The title says it all: what is special in Application Programming Interface documentation compared to general technical writing? What aspects should I take care of?
Answer: API stands for "application programming interface".  API documentation is addressed to programmers who will use that interface to accomplish some task.  While all technical writing is addressed to someone who's trying to accomplish some task, and while some of those people (and tasks) are deeply technical, API documentation has some special considerations:
API reference documentation is essential.  Sometimes this is the only documentation you get; sometimes it's accompanied by other doc which I'll get to.  For each element (class, REST call, etc), API reference documentation presents the syntax, parameters/arguments/options, return values, restrictions, error conditions, inheritance relationships (if applicable), and a (usually concise) description of what it does.  Good API reference documentation includes overviews (for example at the class and package level) as entry points ("how do I use all this stuff together?") and good, focused examples.
API reference documentation is usually generated from comments in the source code, using tools like Javadoc, Doxygen, and Sphinx and following a standard format.  For example, here is the top-level page for the Java API, and here is a reference page for a single class.
API documentation includes other elements. Too often it doesn't, but (to continue our Java example), if you go to the top-level page for the Java doc set, you'll see overviews, tutorials, tools, and more.  Oracle labels only the reference documentation I described in the previous paragraph as "API documentation", but the Android developer documentation takes a more integrated approach that leads with "build your first app" (tutorial) and "sample code".
Examples are important, and I don't just mean "here's some code".  In the Android doc, each entry on the examples page is a link to a GitHub repository containing an introduction that lists requirements, describes the example, and tells the reader where to get help.  (It's accompanied by the actual source code.)  Example code needs to be clean and well-commented, but it also needs to be presented in a context.
Answer: I would say an API needs reasonable examples of use, and needs attention paid (or links provided) to other closely related elements of the API; even if it is just like "See xyyGraphInit".
You want your programmers to be able to use the product quickly and without having to read the whole dang thing five times. I can (and have had to) read through a list of a hundred routines in an API, and finish that task with hardly a clue of what to do first, or how to get what I wanted.
IMO that is a badly documented API. The API is supposed to help me (the applications programmer) get to the useful things in your product, if your API just explains individual routines and doesn't make it obvious how to make your product actually do work for me, then the documentation is bad.
Most APIs that I have used require several calls to set up and get something done, and many such combinations to accomplish such tasks; for example there may be a hundred types of interactive graphs it can produce.
Other technical writing doesn't necessarily have all these interacting parts and subsets of options and everything else. Code is special in that way, and documentation should provide some guidance on not just the individual routines, but how they are related to each other and how to use them together.
Answer: First of all, let's make it clear, what API means. API stands for Application Programming Interface. API is a set of tools, communication protocols, and subroutine definitions for building software. Generally speaking, API is a kind of communication channel that allows two separate programs to communicate.
How does it work? API is also a part of your daily life. For example, you need to turn on your TV from a distance. You press the ON/OFF button on remote control and the TV turns on. This is how API works. Radio/infrared waves through which a remote control communicates with a TV set act as an API in this case.
APIs can be divided into three groups:

Software API
SCPI (Hardware API)
WebAPI

Technical writers develop documentation that includes instructions about how to effectively use a hardware (SCPIs), web-API, or software API. Usually, API documentation contains all the information required to work with the API; it also contains details about classes, functions, arguments, and the like, supported by examples and tutorials. API documentation is usually created by means of regular tools and editors.
More information why this documentation matters is here: What is API Documentation
Comment: "API is a kind of communication channel that allows two separate programs to communicate." Not necessarily. Every library has an API, but the library and the using code are part of the same program. Indeed, that's the original use of the term API; the interfaces between different programs were formerly just called protocols. The language changed in that respect, but I think it is important that an API does *not* imply several programs. It just implies several software components.
Answer: In one sense you could say, Nothing. All technical writing should be clear, give good examples, etc.
The main thing that comes to my mind is that for an API, you pretty much have to have the bulk of the document be reference. That is, you have to list all the API calls, give all their parameters, etc.
It would be a really good idea, by the way, if you actually explained what each call does and what all the parameters are and what they're for. I've read several API docs that just list function names and parameter names and data types and that's it.


How to connect IDE HDD to motherboard with only SATA?

Question: I have a pretty old HDD with IDE cables, and a relatively new motherboard (ASRock 970 extreme4) with only SATA inputs. Is there an adapter or device that will allow me to connect the old IDE HDD directly to the new SATA motherboard?
Comment: I'm not sure how this is technical support request, @artofcode is it okay if I edit the question for the user? He is wanting to know if there is anyway to connect an old IDE drive to a sata mobo. One way or another he will need a piece of hardware, either an adapter or a new HDD...
Comment: @BigElittles I can't say aye or nay to that. If you can edit without changing the meaning of the underlying question, go for it; if you're planning to change what gets asked here, you need to communicate with the author.
Comment: @artofcode That works, I guess I won't be getting my nike money then... I just wanted to say that I'm back to this stack and I'm agreeing more and more with the how the on hold status is being used. Now if you excuse me, I have this question to answer lol.
Answer: So, what you are going to want is an internal adapter. You have to be careful when doing this because poorly made ones can fry a motherboard really quick. I've seen cheap ebay adapters take other components hostage as well.
I did find the Vantec IDE to SATA converter on new egg. It has a 4 out of 5 star rating across 270 reviews. If this exact model doesn't fit with your current motherboard, because of tray restrictions or space issues you can also buy the adapters that are just the wires, without the plug interface the model above uses.
The most important thing is to find a product that has a lot of positive reviews. Like I've said, I've seen some of those power adapters kill a system. So do your homework and look at the reviews. Also with these old IDE drives, remember to have the pinout set to master.


What should our FAQ contain?

Question: Coming from Programmers where we've had entire wars over site scope and the FAQ, I think it'd be good to get this hammered out as soon as possible. So what should the FAQ contain?
Comment: Oh, I agree. One of the first things we settled on Christianity.SE (where I'm a mod) was the site's definition of "Christian".
Comment: This is definitely a good thing to settle as soon as possible. However, given that this beta has been live for less than half an hour, I don't think we've seen enough questions to get a feel for what works, what doesn't, and what should be clarified. In other words, I don't think there's enough information yet to answer this question well.
Comment: I suppose we could start off with the most obvious ones, which might not actually be frequently asked questions, but still questions that are good to have in a FAQ. Such as "What is Blender".
Comment: Oh, I'm well aware of that, I just like getting things nailed out early...really, really early.
Comment: Perhaps it makes more sense to think about the FAQ after some period of time, repeat questions or questions with a lot of votes will start to emerge and from that list you will get meta questions that tend to be a combination of a few more common questions - those are the kinds of Questions that FAQ are great for.  But also we'll want to see a few 'First Principle' topics that help shape how someone might think about asking questions and finding solutionsm, like: "do i really need to ask this question or should I google it first for 10 minutes"
Answer: Wait a few months, see what questions people ask frequently, and there's the answer to your question.
Some websites have fabricated FAQ pages.  They guess at things visitors might want to know, and write questions and answers.  Maybe the information is accurate and useful, but the FAQ concept is treated a writing format. The worst-offending sites don't even have a good description of what they're all about, who runs it, what they offer - it's all shoveled into the fake FAQ.  "Frequently Asked Questions" ceases to mean much.
We shouldn't do that.

What should our FAQ contain?


Gooluck wins app is missing from google playstore

Question: I installed GooLuck Wins on my previous phone but it was stolen. I got a new phone but I can't find the app on Play Store. Even after I signed into my Gmail account, the app is not still reflecting in my Play Store. I tried re-installing but it says 'item not found'. Please what do I do?
Answer: According to AppBrain, that app was unpublished from the Play Store on June 9, 2019, so that's why you are unable to find it in Play Store. Also, I couldn't find a trustworthy place to download its APK from, so can't recommend any non-Google app store.
In the future if you ever come across this situation again with any other app, do a Google search and visit appbrain.com links if they are listed in the search. This site is helpful to get status of an app available in the Play Store, including unpublished ones.
Comment: I forgot to add that I am not affiliated with the website concerned.


networkIds: what happens if two unrelated parties create a network with same ID?

Question: Is the network ID truly unique? It's hard to believe this, as it's just an integer.
Comment: Someone will probably chime in with a more detailed explanation. In summary, they have different Genesis Blocks and disregard each other.
Answer: A geth node must have the same networkid as well as the same genesis block in order to join a network. The geth node also needs to know the enodeid of the peers you want to connect to. The geth client has a hardcoded list of bootnodes for the mainnet and official testnets.
You'll simply be connected to a different network if you have the same networkid but the genesis block is different.


Does the Dunning-Kruger effect still work the same if the incompetent person is aware of this effect?

Question: Is it possible for an incompetent person to reevaluate his abilities (to become more realistic about his abilities) when finding about the Dunning-Kruger effect?
Comment: this reminds me of the [Hofstadter's law](https://en.wikipedia.org/wiki/Hofstadter%27s_law): "It always takes longer than you expect, even when you take into account Hofstadter's Law."
Comment: Welcome. Can you add some backgrounds to your post? We ask people to add their prior research, and simply adding some backgrounds oftentimes already helps a lot.
Answer: One critique of the Dunning-Kruger effect is that it is just regression to the mean. I.e., there is an imperfect correlation between perceived an actual ability. A consequence of this is that people low in ability will overestimate and people high in ability will underestimate. Of course, in some domains, we also see a leniency bias whereby people in general have an inflated sense of their ability. For a discussion of these interpretations see this post by Tal Yarkoni.
But in general, there are ways of increasing the correlation between perceived an actual ability. The basic principle is to provide people with feedback on their performance that is accurate. And presumably, it would help to persuade people that it is trustworthy.


Creating web application/site collection sharepoint 2013

Question: I've just set up Sharepoint 2013 and I can access this site and the central administration. I'm trying to make another Web Application, but cannot access this page. I'm not sure if this is the problem, I named my Host Header: Intranet.companyname.com. When I went to add the host on the DNS I added it under our current DNS location which is named: companynameops.companyname.local. So, when I added the host I added Intranet and the rest is filled in with companynameops.companyname.local. This leaves the FQDN as Intranet.companynameops.companyname.local. Is this my problem? Also, if I go to Designer to open it only shows me the central admin and my default site, it does not show the new Web Application that I created.
Comment: What error you are getting? Did you point your DNS to sharepoint server?
Comment: I'm getting This page can't be displayed. Is the problem because the FQDN in DNS is different than the URL name that I made in SharePoint? I'm thinking I need to make an alias in DNS so that it points to the right name?
Answer: Couple of things to check

When you create the DNS record then make sure it is pointing to correct SharePoint server
Update the AAM setting with the correct URL
also check the IIS bindings.

Note:
When you create new web application then Use the exact the same FQDN as you created in DNS. Also Make Sure the AAM also reflecting the same FQDN there.
Comment: Comments are not for extended discussion; this conversation has been [moved to chat](http://chat.stackexchange.com/rooms/48619/discussion-on-answer-by-waqas-sarwar-mcse-creating-web-application-site-collecti).


Causality of Linear Phase Filter

Question: If a digital LTI filter has phase response on the form $arg[H(e^{jw})] = -\alpha\omega$, what could one say about it's causality (and consequently, the causality of it's impulse response)? Also is Linear Phase a characteristic of only Causal FIR Symmetric Systems?
Answer: For a generic value of the group delay $\alpha$, the filter has a 2-sided infinite impulse, and is therefore not causal.
Causal linear phase systems are (almost) always FIR systems with any of the 4 types of symmetry.
In these cases, the group delay is multiple of 1/2 (0, 1/2, 1, 3/2, etc.).
You can have causal linear phase IIR filters, but these are not of finite-order (cannot be implemented with a difference equation), so they are of little use in practice.
Comment: I'm not sure what you mean by causal linear phase IIR filters. If you have an infinitely long impulse response with the constraint $h(n)=0$ for $n<0$ (causality), and a symmetry constraint due to the linear phase requirement, then I'd say you can't have a causal IIR filter with exactly linear phase. However, you might mean something else. Could you elaborate?
Comment: If you have symmetric denominator you will have poles on or outside the unit circle. So while they are causal and linear phase, they will not be stable. What Juancho refers to might be some non-trivial structures where you run the data in blocks forward and backward and therefore ends up with linear phase (no good explanation, but it is quite non-trivial...).
Comment: @Oscar: OK, I was actually implying stability because otherwise the systems are not useful. And the forward/backward trick is in fact non-causal. So I'm still not sure what Juancho meant.
Comment: @Matt L.: Sorry I missed the "'t" in "can't"... Hard to know the level of the questions asked sometimes...
Comment: I would like to add that, while the classification into four categories is technically correct, for practical purpose there are filters that have an arbitrary group delay. A fractional sample shift of any of the mentioned types gives any desired group delay but at the same time makes the impulse response infinite. Machine precision truncation does still give a finite response and is practically indistinguishable from a real linear phase filter.
Comment: Oh, and these infinite response filters are probably what Juancho referred to.
Answer: You cannot really tell whether the filter is causal.
However, you can tell whether the filter is definitely not causal (at least for FIR filters). We have

$\alpha < 0$: not causal (whether it is acausal or anti-causal is not known).
$\alpha \neq 0,1/2,1,3/2,2,\ldots$: acausal (but not anti-causal)
$\alpha = 0,1/2,1,3/2,2,\ldots$: unknown (can be causal or acausal)

The reason is (as Juancho) already pointed out, the symmetry in the impulse response for linear phase filters (which makes the group delay $\alpha$ equal to half of the length of the impulse response minus one ($(N-1)/2$).
Comment: Just clarifying: (length-1)/2, i.e. order/2. (Rather than length/2 - 1, which the sentence also could be interpreted as.)
Comment: @Oscar, thanks. I meant that, but I agree it is ambiguous.

Causality of Linear Phase Filter


Choosing the right prepositions

Question: My sister hates being late for work. She likes to arrive __________ time.
I know the answer is "on". What about "in"? Can we also use it in this case?
Answer: I'd say it depends on how 'accurate' you need to be...
"on time" implies 'at the correct moment, exactly' [with some slight leeway, but not a lot]
"in time" simply implies 'at some point before I ought to be there' - it has a greater element of 'early'.
Examples...

The train arrived on time.

The train was due at 08:57, it arrived at 08:57, exactly on schedule.

I was due to be at work for 09:00, I arrived in time.

You may have arrived at 08:59, but you probably allowed some extra, so were there early, 08:50 or so.
These are not absolutes, but each version hints towards either a specific or more general time of arrival.
"in time" has an even earlier variant "in plenty of time" meaning you arrived at work well before your specified start time, maybe 08:40 - but these 'measurements' are relative to the situation & very variable.
Some people might consider being at work 2 minutes before their appointed time to be 'plenty'... others may not.
Similarly, some people might consider 'on time' to be within a few minutes either way, early or late.
Answer: Given a choice between "on" and "in", I would agree that "on" is the better answer in this case.
"On time" usually implies that there is a specific deadline that must be met, eg the time that your sister starts work.
"In time" usually implies that some other event is going to occur, possibly not at a precise time, and the subject wants to arrive before the event occurs. For example:

We arrived at the airport in time to see her plane land.

The difference may be better understood by the following sentence.

We did not arrive on time for the start of the school concert, but we arrived in time to see Sarah's performance.

As for your sister's work habits, if she hates being late, she would be better off arriving before time instead of on time.

Choosing the right prepositions


Is it mandatory to show my credit card upon my arrival at hotel booked using Booking website?

Question: My cousin is going to book a room for me in Istanbul using his Mastercard. I've heard that the hotel may ask me to show the credit card with which the payment was made. If the cost of the hotel is fully payed using the Mastercard, do I still need to show the credit card?
Comment: It is very likely the hotel will accept an other credit card or you showing the one it was booked on with a letter of explanation of the owner of the card, but not accept you without a credit card nor with a card not on your name without a good explanation why you do not own that card. But as in the other comment, only the hotel can tell, contact them.
Comment: Do you have an other credit card for your expenses and probable damages in the hotel?
Comment: @Willeke thank you for your help. No I don't have any other card. I will only carry cash with me during the trip.
Comment: @Willeke thank you. I try to contact the hotel about this issue.
Answer: Any hotel will almost certainly ask you to swipe (any) credit card upon check-in for security against other bills you may incur in the hotel (restaurant, mini bar etc). Some may take a debit card or even cash, but best to check with the hotel in question if in doubt.
I have not heard of hotels requiring the same credit card as used in the booking to be shown, but again, check with the hotel (or Booking.com) if in doubt.


Are there any tools for scanning for SQL injection vulnerabilities while logged in?

Question: Some pages of my website were vulnerable to SQL injection. The injection worked only when the user was logged in. I have now fixed this problem, and now I want to make sure that no similar problems remain. I have tried scanning with sqlninja and sqlmap but neither program has a provision to give website login details. Are there any tools that can scan for injection vulnerabilities with a logged in session?
Answer: Let me offer you an easier alternative.
It is your website. You have access to the source code. Look through it and verify that all your database queries are parameterized. This is much much more efficient than scanning your website in the hopes that the tool you use tries the right injection at the right place.
Comment: The code is too big.Also If I get some scan report, I can submit it to my clients as proof.
Comment: @symcbean I respectfully disagree. Some attacks are pretty difficult to secure against just through code reviews but SQL injection isn't one of them. Just ensure that every single database call is parameterized and you will be fine.
Comment: You can't prove that code is secure - OTOH relying exclusivley on security by design (code review) without testing it is downright silly. SQLMap does support cookies - just login using a browser and copy the cookie into your test script.
Comment: @symcbean and Terry, I don't think there's any disagreement here. Both of you are saying the right thing. Both of you have good suggestions, now we just have to combine both of them. `Review the code + test with tools = Good stuff`.
Comment: ^ This is the best advice you can get, if there are parameters your tool does not test for, you are screwed.
Comment: Nice idea, but if you have a problem, you don't always have time to read through 1+ million lines of source code in 200 different files to find a problem. Sometimes a tool can find the problem (or an instance of the problem) in just minutes.  If you're currently 'under attack' reviewing the code is probably only feasible on very small projects. Not saying that it's a bad idea of course - I'm just saying that reading millions of lines of code is  not "more efficient than scanning your website" in all cases.
Answer: There is a cookie option in sqlmap :

--cookie=COOKIE     HTTP Cookie header

So you just need to paste your cookie and you will be able to use sqlmap as if you were logged.
If you need the list of all the options : https://github.com/sqlmapproject/sqlmap/wiki/Usage
Answer: You don't "fix" SQL injection problems. Well, people do, but that's wrong. What you must do is not to allow them to happen in the first place. The main tool for that is, as @TerryChia points out, parameterized SQL statements. Parameterized SQL statements are very effective at preventing SQL injection attacks, by being a generic and thorough solution; this is much better, incomparably better, than any kind of "input data sanitation".
SQL injection attacks occur because the Web site is trying to interpret user-provided data (field contents) as code (SQL is a programming language, after all). This implementation strategy is doomed. It cannot be really "fixed"; see this answer for some conceptual discussion on this subject.
"When the only tool you have is a hammer, then all problems have better be nails, because you're gonna hit them repeatedly on the head." Be aware that parameterized SQL statements, though widely applicable and efficient (more than traditional "dynamic" SQL statements), cannot do everything; there are very rare and specific contexts where dynamically building up SQL statements is the only solution. But this is not your situation -- you would already know it, and also all that I write in this answer.

SQL injection "testing tools" are not satisfactory in any way: they are not meant for ensuring security, but for attacking the "low-hanging fruit". They will miss the overwhelming majority of possible SQL injections. Their purpose is to allow a non-technical attacker to nevertheless believe he is some kind of elite-level hacker; or to automate attack attempts on thousands of distinct sites. What these tools will tell you is one-way: if they succeed in breaking into your site, then you know that the site is extremely vulnerable; however, if they fail, then you know nothing.
Nevertheless, if you want to get a tool past a "login session" system (despite all that I have explained above), then it depends on how the login is managed. Most Web sites will use a "login page" which results in setting a cookie value in the client; that cookie represents the "logged in" state and it suffices to send it back to the server to be considered as part of the "session". SQL injection test tools allow you to include arbitrary cookie values in the request, which is what you are asking for. See, for instance, the sqlninja documentation (search for the second occurrence of the "cookie" word in that page).
Answer: You can use webslayer. https://www.owasp.org/index.php/Category:OWASP_Webslayer_Project.
Webslayer is an application brute force/Fuzz application. To check the injection after login, follow these steps.
You will need the following, A browser and an intercepting proxy like webscarab (or tamper data addon of firefox will do.).

Login into the application using the browser.
Using the intercepting method, get the cookies of the logged in session. (If you are using webscarab or an intercepting proxy, you can copy all the request headers.)
Start webslayer and paste the details into the headers coloumn in webslayer.
Input the URL/Request you want to test SQL injection against.
Add "FUZZ" as the keyword where you want to test for injection
Select your payload
Hit start

Steps 3 - 7 is the standard working of webslayer, which you can get a tutorial on. There are lot of videos for that in Youtube like (http://www.youtube.com/watch?v=QGNyvXIcky4)
This will help test any injection vulnerabilities in a logged in session.
Answer: Most well-written web applications have a central login or session validation logic. What I do in these cases is simply comment out that part of the code in the development server. Now all my tools have access to all of the functionalities.
Answer: I am not aware of any tools that can do post-authentication SQL injection discovery via sqlmap, but I can describe the manual process here.
First, you login to a website, while capturing all the HTTP requests and response via setting up the browser using proxy, and Burpsuite as the proxy.   Now we will focus only on the post-HTTP authenticated requests.
https://portswigger.net/support/configuring-firefox-to-work-with-burp#:~:text=Select%20the%20%22Manual%20proxy%20configuration,(by%20default%2C%208080).
Next use the Burpsuite to extract out the "curl" command to replay the URL against the webserver.   Select those URL (usually POST request) that you actually have to provide input to the webserver.   If you replay the entire URL against the webserver, most likely it will be successful.   The POST URL should contain the cookie plus other parameters in the HTTP requests.   Try experimenting with removing some of the HTTP headers, and you will realize that just the cookie alone sometimes DOES NOT work.  (eg, the Asus router webserver, it does not just depends just on the cookie but other elements in the HTTP headers are involved as well).   This is why sqlmap's "--cookie" may not work because authentication may be spread over multiple HTTP parameters in the headers.  So "--headers" may be needed to successfully replay the URL requests.   If you can replay successfully the URL (meaning the HTTP response does not contain "you have been logout" signature) then the entire curl command should work when modified to use "sqlmap" as the command instead.
The sqlmap parameter "--auth-type" and "--auth-cred" is only for preauthentication requests.   For many authentication which I am aware of (eg, Asus router) it does not correspond to any of these types, and so there is no way to use this method.    The reasons I suspect is because basic authentication is not secure - it is just "username:password" base64 encoded data passed directly over the web.
Answer: Parameterized SQL statements is the only reliable answer to your probem. Maybe sqlmap or havij fail to identify the vulnerable parameter but a determined and skilful hacker might. So, to be on the safe side secure sanitize all your database queries.


Using OSM for routes?

Question: Does anyone have any tutorial, link, video etc on how I can use Open Street Map for routes?
I know google maps and saw that I can easily do that. But this application will have an internal module and we can not afford the license.
Comment: https://wiki.openstreetmap.org/wiki/Routing/online_routers and https://wiki.openstreetmap.org/wiki/Routing/offline_routers and https://wiki.openstreetmap.org/wiki/Routing and https://wiki.openstreetmap.org/wiki/List_of_OSM_based_Services#Routing
Comment: http://project-osrm.org or http://openrouteservice.org perhaps?
Comment: www.switch2osm.org ?
Comment: You want to create (single) routes, or add a routing service to your own site?
Comment: I want to add a routing service to my intranet. This service is to calculate the shortest route between origin and destination requested based on the mileage and calculate a value. How is an internal application can not use the google maps api.
Answer: GraphHopper (using OpenStreetMap Data)

GraphHopper offers memory efficient algorithms in Java for routing on
  graphs. E.g. Dijkstra and A* but also optimized road routing
  algorithms like Contraction Hierarchies. It stands under the Apache
  License and is build on a large test suite.
OpenStreetMap is directly supported from GraphHopper. Without the
  amazing data from OpenStreetMap GraphHopper wouldn't be possible at
  all. Other map data will need a custom import procedure.

Video
https://www.youtube.com/watch?v=HBVe_E5j0TM
Answer: The other answers on this page provide some great specific details - but I think a more general answer to the question is in order (not least for future viewers with similar problems):
There are many many methods to work with routing based on Openstreetmap data. A key information page on this is the OSM wiki page on routing It's important to understand that the services available on any one Openstreetmap based website, or from any one tool, will be limited - an in particular that the website openstreetmap.org isn't designed to be a one-stop-shop - that the value in the Openstreetmap project comes from the huge range of services, maps and apps based on the OSM data.
If you go looking you'll find a large number of tutorials and websites offering information about how to work with the many different possible individual solutions to your question. Simply 'how to do routing based on Openstreetmap' is a very big subject.
Answer: pgRouting is another routing option using OpenStreetMap data.  pgRouting.org
pgRouting extends the PostGIS / PostgreSQL geospatial database to provide geospatial routing functionality.

Core Features pgRouting provides functions for:

All Pairs Shortest Path, Johnson's Algorithm
All Pairs Shortest Path, Floyd-Warshall Algorithm
Shortest Path A*
Bi-directional Dijkstra Shortest Path
Bi-directional A* Shortest Path
Shortest Path Dijkstra
Driving Distance
K-Shortest Path, Multiple Alternative Paths
K-Dijkstra, One to Many Shortest Path
Traveling Sales Person
Turn Restriction Shortest Path (TRSP)
Shortest Path Shooting Star

Here's a link to their workshop / tutorial : workshop.pgrouting.org
Comment: In this case I'll have to upload a shape of streets into PostGIS?
If in case there is a new road, for example, will have to refzer uploading.
There is a ready api like google maps? Openlayers makes routes?
Comment: Yes, you need to download OSM data, then import it into PostGIS.  I have used osm2pgrouting which automatically converts to pgRouting compatible.  For new roads, you can download the weekly changeset from planet.openstreetmap.org and import that with osm2pgrouting I believe, though I have not tried that yet.
Answer: We provide a free OSM converter, which you can use to import OSM data into our routing solutions. Could be either RW NetServer 3 (standalone server application) or RW Net 4 (.NET component). Both can be seen on www.routeware.dk and provides standard features such as routing, driving directions, travelling salesman optimization etc.

Using OSM for routes?


Impact of news coverage on ecomomy

Question: I was wondering whether there exists a study which measures the impact of economic news coverage to gdp or something like that
Comment: This is more like an event-study, this method is well utilised in Finance...
Comment: at the moment I am writing a paper about this, As it is very hard to find earlier studies about this subject, I wanted to know if I missed any sources of information ;)
Answer: I have not heard of such a study and I have a feeling studying how a daily news item would affect an annual measurement value would be a pretty futile experiment.
However, there are some studies on how announcements from central banks or other financial authorities might affect expectations in the short run. My collaegue actually did her licensiate thesis on how ECB board announcements affected the growth path of euro inflation.
A pretty recent article would be Moessner, R.: "Effects of ECB balance sheet policy announcements on inflation expectations." in Applied Economics Letters and that might be a good place to start looking.
Answer: Nick Bloom, from Stanford, and some co-authors develop indices of economic policy uncertainty for the world's major economies. Their Economic Policy Uncertainty Index is based on newspaper coverage frequency of policy-related economic uncertainty. In case this is useful, their web page explains the methodlogy and the applications.

Impact of news coverage on ecomomy


Is "barista bar" redundant?

Question: I am editing something that mentions a "barista bar." Is this redundant? Is it like saying a "bartender bar"? If I'm not mistaken, a barista is the Italian word for a male or female bartender, and refers more casually to servers at a coffee bar. So it doesn't make sense to me to use it with "bar" or even "coffee bar" or "cafe." Or am I missing something?
Comment: Is it about a bar for baristas or is it a bar run by baristas?
Comment: No, it's about an employee cafe at a large corporation where employees can get lattes, espressos, and many different coffee drinks made by baristas.
Comment: Does the bar only serve coffee-based drinks?
Comment: The bar serves coffee and tea drinks. But no food and no other kinds of drinks. The variety of drinks is extensive.
Comment: A barista is a person who works at a coffee bar.
Answer: Barista bar is not very common. Googling it mostly seems to return proper names (bars with barista in the name).
When I read barista bar without any context I'd think it's a bit odd and could have two meanings: a bar for baristas or a coffee bar (because I'd associate barista with coffee). In the first case it seems fine (although a bar for baristas is less ambiguous) while in the second case there are better alternatives.
Since you mean the latter, I'd go with coffee bar, hot beverage bar or just bar. The first implies the bar specialises in serving coffee and perhaps other hot beverages avoiding any ambiguity. The latter is more general and might be associated with bars serving alcoholic beverages.
Comment: @Lambie to see if it might be a common phrase. A *cop bar* or a *menu bar* are often used, but not everyone will have heard about those terms.
Comment: @Lambie Because googling is easy and provides information.
Comment: Why would one bother to google this? Would you say a restaurateur restaurant?
Answer: Only saying "bar" would be ambiguous.
In Italy, a "bar" is more like a coffee shop–think of Starbucks–than a British "pub" whereas, in the US, bars normally serve alcohol.

The 10 Most Popular Drinks to Order at a Bar (Esquire)
16 Classic Drinks to Order at a Bar (Town&Country)
The Hanky Panky is a real classic, invented by the legendary Ada Coleman at the Savoy's American Bar. (Drinks International)

You do not go to a barista to get coffee, a barista is someone who makes and serves coffee and any other drink available on the menu. Despite being relatively recent, this Italian loanword is used all the time.
A  "barista bar" would, therefore, suggest a bar which specializes in serving hot and non-alcoholic beverages often accompanied with light meals or snacks.
Although perfectly comprehensible, the expression "barista bar" is essentially inappropriate. The word the OP is looking for is to be found among the following:  "cafeteria", "coffee shop", "coffee bar" or in the UK, a cafe (also café).
Answer: While I would agree that the term "barista bar" seems redundant, I could see a situation in which it may be used.  For instance, the place may also has a salad bar where employees tend to eat, and to which they refer often.  In that situation, it may be useful to specify that the bar you are talking about is not the one with the salad, but rather the one with the baristas.
 Additionally, when deciding where to meet, some might find the phrasing "would you like to meet at the salad bar or the bar?" a bit awkward, and may say "salad bar or barista bar" instead.  If this happens often enough, the term may find its way into general use around the workplace.

Is "barista bar" redundant?


How to choose Car Tyre Pressure Monitor Valve Stem Cap Sensor Indicator

Question: I would like to fit Car Tyre Pressure Monitor Valve Stem Cap Sensor Indicators to my Skoda Citigo, where the cold tyre pressure is supposed to be 26 p.s.i. There is a wide range of these available, but none that I can find that are specific to this pressure. How important is it to be this specific? If it's not, then what are the criteria should I use when choosing a set?
Comment: 26psi seems very low for what seems like a small tire. Where are you getting the 26psi specification from? 32psi is what I would call a "norm" for tire pressures on passenger cars. What size are the tires on the vehicle?
Comment: [Check these](https://www.accupressurecaps.com/p/accu-pressure-safety-caps-4-pack-26-to-44-psi).
Answer:  shows that a Citigo Elegance 75PS Greentech with 185/55 x 15" requires 26psi on its small/narrow tyres.
You can go for the cheap option by searching for 26psi valve indicator caps which will allow you to visually inspect each tyre without having to get a pressure monitor to check them.
Some aftermarket tyre pressure monitoring tools (such as this one) will let you monitor whether the tyre is correctly inflated by measuring the air pressure in each tyre.  These are better than the ones that just identify a softer/harder tyre by using the turning moment.
As long as they are within 1-2psi of each other that's fine in my experience, however these tools aren't much use in the event of a blow out.  I've not really ever needed them in cars fitted with normal tyres but those fitted with run flats or with "gunk" to stop punctures its useful as the tyre may not look deformed due to low pressure but will affect the handling characteristics of the car.
Comment: It would appear from the sticker, if the vehicle actually has the 185/55-R15's installed, there is a pressure difference between the front and back (F=29psi/B=26psi) ... Also, of the four sizes listed, these are actually the widest tires (with the 185/50-R16's being the same width with a shorter sidewall).
Comment: @paulster yep, that seems right. All my front wheel drive cars have always had higher front pressures.


Can you use 1 python script for multiple GE scenes?

Question: I have 2 scenes, both with logic. I am trying to convert all my logic as certain logic bricks cause small delays. I noticed that if I use python scripts instead, I will end up still sending messages which will lead into small delays. Is it possible to have 1 python script in one scene that does funtions for 2 objects in 2 different scenes? In other words, I won't have to be sending messages between scenes to remove the delay. If so, how would I identify an object from a separate scene? Thanks.
Comment: IDK about different scenes, but it seems like sending a message should be pretty fast. Have you tried making the messaging faster?
Comment: @Matt and how would I do that?
Comment: It depends on a whole raft of things. Probably the most important is the payload. How are you sending the message, and what are you sending?
Answer:
Can you use 1 python script for multiple GE scenes?

Yes, you can.
This has nothing to do with messages, or delays. Python is executed by a Python controller. A Python controller gets executed (as each other controller) either once or never within a single logic frame.
Messages
Messages will be transferred after the logic bricks are executed but before the next frame starts. From perspective of logic - between the frames.
That is the reason why it takes exactly one frame between sending and receiving a message.
Effect:

When you perform operations while sending a message and operations when receiving this message ... you will notify a one frame delay.
If you do not want that, you should ensure all operations (except sending the message) react on the same event -> e.g receiving the message.

... how would I identify an object from a separate scene?

You can grab the scene and read the objects it has.


How to cook the eggplant in trader joe's eggplant roll style?

Question: I want to learn how to make similar style eggplant roll. I cook eggplant many times, but I have no clue how to make the eggplant moist but not wet. I see the eggplant in trader joe's eggplant roll, it is exactly what I want. Should I bake the eggplant?
Comment: I guess this is eggplant wrapped around something, and you're trying to get a good texture for that? If not, can you describe what you're getting at Trader Joe's, or even provide a picture?
Comment: I've had marinated eggplant that was soft enough to fold, but still firm enough to hold a filling ... I have no idea if that's what Trader Joe does, though.
Answer: We have used this recipe as a template for eggplant wrap type dishes.
In this recipe example they use a grill but you can also use a rack inside the oven either baking or broiling:

PREAHT a stovetop grill pan or outdoor grill over high heat.
CUT the eggplants lengthwise into 1/4-inch thick slices (about 6 slices each eggplant).
BRUSH the eggplant slices evenly with olive oil on both sides.
GRILL the eggplant slices in batches for 3 minutes each side.
ALLOW to cool slightly

http://mediterrasian.com/delicious_recipes_eggplant_rolls.htm
Answer: The trick is to draw out moisture from sliced eggplant before cooking - sweating and draining.
This isn't like sweating vegetables over heat - you salt both sides, and place between layers of paper towels for an hour or two. This will draw out the excess moisture while seasoning the eggplant - your roll will be less watery and less bitter.


After death what are the requirements of a next of kin?

Question: After death what are the requirements of a next of kin?
For example after my parents die can I say "I'm not touching that with a ten foot pole"? (Not that I would.) I live in Indiana.
Answer: Nobody is legally required to touch the legal affairs of the deceased. If you have an interest in their affairs (joint ownership of some property), you may have difficulty disposing of your interest other than by abandoning it (unless someone touches it with a 10 foot pole). Their death does not erase your debts. Creditors can sue the deceased and will win a default judgement (defendant failed to show up...), their property can be seized, real estate can be auctioned off for non-payment of property taxes, and so on. At some point, non-physical assets may end up in the state's unclaimed property office until someone claims it. The county coroner will dispose of the unclaimed body.
Comment: Generally speaking, the only way that unsecured debts of a dead person can be enforced is through the probate process, and creditors can't simply obtain a default judgment. Either the public administrator, or a creditor, opens up a probate case and then creditors file claims with the executor appointed in that process, in order of priority. Generally, secured debt holders (e.g. mortgages) can foreclose outside of probate, and landlords/lessor can evict/repossess out of probate, however. Otherwise, I generally agree.
Answer: The only requirements of next of kin (and really they aren't specific to relatives although they often apply to relatives) are to:

Cooperate with the coroner or law enforcement to identify a dead body and to provide information for a death certificate (if asked to do so), and
Lodge a last will and testament of the person who died with a court, if you are in possession of it and you do not know that it has been revoked, within a certain amount of time after the death. You don't have to administer that last will and testament, however, even if you are the person named in the will as the executor.

Next of kin (in common law countries including the U.S.) have no liability for the decedent's debts in excess of their claim to an inheritance, against which those debts are setoff. It is not uncommon for collection agencies to fraudulently say otherwise, however, and this is not universally true in countries outside the common law legal tradition although most Western countries with civil law systems have also adopted this rule.
In early modern times (roughly ca. 1500-1800 CE, but obviously varying by country) in most of Asia and in many continental European countries, however, next of kin were responsible for a decedent's debts, a fact that was a common literary trope.
Generally speaking, the only way that unsecured debts of a dead person (i.e.  those not attached to specific collateral) can be enforced is through the probate process, and creditors can't simply obtain a default judgment after someone dies. Either the public administrator, or a creditor, opens up a probate case and then creditors file claims with the executor appointed in that process, in order of priority. Generally, secured debt holders (e.g. mortgages and car loans) can foreclose outside of probate, and landlords/lessor can evict/repossess the leased property out of probate, however.
If the assets in the estate exceed the debts for which claims have been made against the estate, anything left over in the hands of the executor (either a public administrator or creditor) would be held in trust for the persons named in a will, or who are entitled to the estate in the absence of a will, unless those people can't be located or those people "disclaim" an interest in the estate. If everyone entitled to the assets of the estate disclaims their interest in it, or cannot be found, within a certain amount of time the property is turned over to the state treasurer or other person designated by law, who holds it for a certain amount of time after which it becomes the property of the state.
As @user6726 notes, the coroner will dispose of the unclaimed body, either at the expense of the decedent's assets, or in a pauper's grave paid for via charity and/or government funds.


Can't find recently viewed Contacts in Global Search

Question: I'm a Sys Admin, and one of my users is saying that when she uses Global Search to search for Contacts, most of the time it is not working.  The examples she has given work fine for me when I try and search in Global Search.  One such contact was created back in January, so it should not be an indexing issue.  She can view the Contact via some other means (I gave her the URL to navigate to the Contact directly), but a subsequent Global Search after viewing it still fails to find it. So it's not an access issue.  In the left sidebar where it shows the numbers of matches, it clearly says "Contacts (0)".  So it's not an issue with the types of objects Global Search is setup for.  I checked a couple of SFDC Articles which address this(https://help.salesforce.com/articleView?id=search_crowding_considerations.htm&type=5, https://help.salesforce.com/articleView?id=Object-not-included-in-search-and-results-differ-for-users&type=1), but neither seemed to show anything that might be the cause. So I seemed to have eliminated all the usual causes for this.  Are  there some other potential causes I am missing?
Answer:
Is the contact private (has no AccountId)?
If you click "Sharing" button on the contact (assuming your OWD isn't "controlled by parent") & expand the list - can you see this user all right on the list?
Does she have the Contacts tab on in her app (clutching at straws here)
Are there some contacts that do work?
Is her user's locale set to Hungarian, Chinese, Korean, Japanese? These cultures work in "Lastname Firstname" format.
really stupid idea: any chance you have a custom object labeled "Contact" ;)
Comment: Tried to add Sharing button to the Contact page, but it did not allow me to because sharing setting for Contact is "Controlled by parent".  So looked at the sharing for parent Account, and saw that it's 'Associated record owner or sharing', and it shows that the user owns some Opps whose parent is the Account.  This in turn allows the user to view Contacts of the same Account.  In addition, global search did not work for parent Account either.  So looks like a "feature" which makes global search not find records which the user has access to via 'Associated record owner or sharing'
Comment: Never heard about such limitation, you might want to simply raise a ticket with SF. If you're right - other than explicitly sharing the Account (apex managed sharing? adding her as team member? just manually make an entry in "Sharing" to test the hypothesis) I don't think you can modify the search behaviour... Can you also try tips from https://success.salesforce.com/answers?id=9063A000000iRC0QAM ?


How can you tell if the sound of an electroacustic nylon guitar is going to be good?

Question: How can you predict whether an electroacoustic nylon guitar is going to have a rich/deep sound by looking at its technical specifications?
Comment: @berry120 Agreed. I was tempted once by the Charvel AE that claims everywhere to have 25 frets at the top. Even though I could see in the picture that there are only 24, I went ahead and ordered it. 24. And then the electrics shorted out. Ended up just giving it away because I couldn't stand to look at the thing anymore. Definitely try before you buy. At the same time, it's good to have some background information before walking into the shop, so as not to waste time on some that could've been predicted to be inferior.
Comment: You, well, just can't really - it's one of the reasons I'd always trying out instruments before buying them.
Comment: @berry120 For the electric part, that's quite true. But for the acoustic part, there are indicators to look for. Solid top is better than laminate. A full-size body is better than a "slim" one.
Comment: @luserdroog Sure, there's quality indicators to look for, but I've been surprised at how bad some expensive, technically "good" instruments have sounded to my ears and vice versa - so these days I generally (deliberately) put all preconceptions aside and just go and try the thing out.
Answer: Generally, no.
While you can look out for things like size (full size is better than a small one) and construction as @luserdroog says, there are so many variables that you need to play an instrument to see how it works for you.
Your playing style may mean a particular type of instrument works for you while it might not for me (for example if you use a heavy pick hand and I play flamenco style)
The circuitry could also be very variable, and even the pickups can change the sound, sustain, tone etc.


Making Mulberry Cider

Question: Has a mulberry cider been made? I have a mulberry tree that has so much fruit every year and was wondering how I would go about trying that? I've only just bottled my very first batch of beer....so very new to this!
Answer: It might take a huge amount of fruit to make a substantial batch of say 5 gallons.  I would be more tempted to create a mulberry flavored cider with apple cider as my base.  You can find cider that hasn't been treated with any preservatives fairly easily.  They have yeasts designed for cider or I've used champagne yeast with good results. As popular as cider has become there should be a multitude of recipes out there.
Comment: What do you reckon is a huge amount?
Comment: 4lb of fruit per gallon of wine, from this recipe: https://www.homebrewit.com/mulberry-wine-recipes/

Making Mulberry Cider


Reputation for useful flag

Question: Since flags tend to improve this website quality and tend to reduce 'noise' in the question thread: would it be a good idea to give a small reputation amount for an helpful flags?
Comment: No, flagging is working fine as it is. We don't need more ways for people to go hunting for things to flag and add to the moderator workload, just because some rep is on the line.
Answer: We already provide an incentive to give us helpful flags with the Deputy and Marshal badges. Plenty of people flagged happily before those badges came into existence, and many more do now that they are around.
Frankly, I want people to be flagging things because they're motivated to keep the site clean, not because of some arbitrary points. We only need flags for the items where moderators really do need to step in (or for low-rep users who can't yet vote to close posts).
We already have some trouble with people who farm helpful flags to game the existing badges, and if reputation was involved that would get much worse. Not to mention the fact that we'd get called out for every single declined flag on Meta because they didn't get reputation for them. I would not look forward to that.
Comment: How can you have trouble with helpful flags ???
Comment: Maybe 'farming helpful flags' means viewing existing flags, duplicating them, and hoping that the other person was correct so that your flag will be "helpful".
Comment: @CarlG How is that a problem? Doesn't that just increase the visibility of an existing flagged post in the review queue? If the flag is incorrect, the user messed up for themselves. If it's useful, well, it increased the likelihood that off-topic content was handled.

Reputation for useful flag


What is the difference between a Library call and a System call in Linux?

Question: I would like to know what is the difference between a Library call and a System call in Linux. Any pointers for a good understanding of the concepts behind both will be greatly appreciated.
Answer: There's not really such a thing as a "library call". You can call a function that's linked to a shared library. And that just means that the library path is looked up at runtime to determine the location of the function to call.
System calls are low level kernel calls handled by the kernel.
Comment: So if somebody ask the above question i can interpret it as the difference between a System call and a Function Call.
Comment: "man ltrace" gives my "A library call tracer" :)
Answer: If you type man man in your shell, you will see the list of the manual sections

2 System calls (functions provided by
  the kernel)
3 Library calls (functions
  within program libraries)

For instance, you will find chmod in the section 2 of the manual when typing man chmod. And fprintf in the section 3.
Answer: System calls are handled directly by the kernel.
Library calls are handled by a dynamic (or statically linked) library.  The program making the library call must first import that library, before the call will work.  The library calls themselves may use system calls.
Sometimes libraries are provided as "front-ends" to system calls, to provide extra functionality or ease of use not provided by the kernel.
Comment: Library calls are not necessarily handled by a dynamic library. Libraries can be statically linked so no import (load) is required.
Comment: True.  I added that info.
Comment: Only half of it...
Comment: shouldn't function in head only file also be part of library calls?
Answer: Basically there are two modes of linux kernel viz.

User mode,
Kernel mode.

Any linux kernel switches itself back and forth between these two modes.
Generally, Library calls get executed in User mode and System calls get executed in Kernel mode. In operating system terms, Kernel mode is Atomic in nature and its in Supervisory mode.
Almost all Library calls need help from the kernel to perform its tasks. Each library call in turn calls underlying system call.
Let us make idea more clearer using following example

fopen() : is a Library call,
open()  : is a System call.

Whenever in c program, you use fopen() from  header file. Programming environment calls system call open() from kernel and perform its file opening task. Again after executing, control flow return to user mode.
To illustrate this perform following tasks

man man: here you will find manual section from 1-8 each has specific purpose.
Do man fopen : you will see respose as FOPEN(3), here 3 indicate manual section 3 of man pages which is c-library calls section.
Do man open :  you will see respose as OPEN(2), here 2 indicate manual section 2 of man pages which is system calls section.
Hope you understood the concept.
Comment: The kernel has only one mode, kernel mode. User processes have two operational modes they switch back and forth, userland and kernel.
Answer: Just adding to the differences mentioned here in other answers.
Since a library call is simply a function call, no switch from user space to kernel space occurs. On the other hand, a system call results in a switch from user space to kernel space because the system call operates in kernel mode.
Answer: System calls are functions that the operating system provides for applications to use. Whereas functions like the ones in math.h, string.h, etc are those that doesn't have anything to do with interfacing with the operating system.


Question About Fluorescent Ballast Substitution

Question: I have a fixture that uses one 36" T12 lamp. The recommended replacement ballast is a GE140RS120DIY. I am unable to find that ballast. I purchased a GE240RS120DIY ballast and wired it in.  I wire nutted the two yellow wires with one nut to a wire. The new ballast is for two 48" lamps vs. one 36" lamp. It won't light and I'm wondering the reason why. Is there a way to wire it so it will work? Right now I'm two red to one end, and two blue to the other end of the 30 watt lamp.
Comment: Why not trade the whole thing in for an LED shop light? They cost about the same as a replacement transformer, use less wattage and should last much longer.  They also avoid the problem of breakage and disposal of mercury containing fluorescent tubes.
Comment: Or simply an LED "tube" that fits into the lampholders, and rewire the lampholder on one end to supply 120v direct (per the tube's instructions). Of course this requires a non-shunted lampholder on the 120v end,
Answer: Many ballast can be connected to 1 or 2 lamps some different lengths. The wiring may be different than your original (colors) look at the picture on the front of the ballast if it only shows connections for 2 lamps it probably will not work with just 1 lamp. This ballast should work found on line 13$.  Fulham Fluorescent Electronic Ballast 120V for for (1-2) F32T8 (2) F25T8, F32T8, F25T12, F30T12, F3... by Fulham
Answer: You're wiring it contrary to its wiring diagram (on the label and on the spec sheet, found by googling GE240RS120DIY (you misspelled the part number).  A single F30T12 is also not supported by that ballast.
Look for other ballasts which will support that bulb such as the GE240RS-MV-N.
You can also look for ballasts which take T8 bulbs.  T8 bulbs will physically fit in T12 fixtures, however they do need a matching T8 ballast.
Edit: BETTER YET, get an LED "tube" replacement. It looks like a fluorescent tube, but it's made of LEDs.  Here's the gotcha.  Some of them, you rewire the fixture to put 120v directly on the pins of the ballast (called direct-wire).  Others are "plug and play", meaning they cope with the weird voltages that come out of a ballast, and expect you to leave the old ballast in place.  This is marketed as a time-saver, but is worse than useless if your goal is to get rid of the ballast entirely.  You want 'direct-wire' if you go that way.
Your fluorescent tube has 2 pins on each end.  Look closely at the sockets aka lampholders aka "tombstones".  There are non-shunting and shunting types.   A non-shunting lampholder has 2 pairs of stab connections, each pair goes to one pin on the bulb.  A shunting lampholder allows only 1 pair, and shunts the two pins together internally.  Rapid and programmed start ballasts use non-shunting, that is, 2 wires to each lampholder.  Instant start ballasts use shunting lampholders (or non-shunting that you have jumpered) and have 1 wire per lampholder.   If your lampholders are shunting, and your ballast supplies 2 wires to each tube end, you need to replace them with non-shunting. This is no big deal, they are pretty standard and cost between 60 cents and $3. A direct-wire LED conversion may require a non-shunting lampholder on one end or both.
Comment: Wolf, I would like to say thank you for all of your information. As long as I've been at this, fluorescent fixtures are still a mystery to me (or at least when they aren't working). This fixture is in my own home in a dropped ceiling that I'm going to eliminate one of these days. I replaced the ballast and everything is working. The info on T8 substitution and shunting vs non-shunting tombstones is something I need to know. I really do appreciate your help and am sorry I didn't respond more timely. This is my first knowledge of Stack Exchange. Guys like you make it a very valuable resource.


Was there a reason Victor Hugo chose 24601 as the number for Jean Valjean?

Question: 24601 has developed into being an iconic part of both the Les Miserables book and musical. Was that number special to him, or was it simply a random number he chose (I doubt it)?
Answer: Yes: it corresponds to the date of Hugo's conception.
This is part of a pattern of similarities between the character of Jean Valjean and the author himself: both are of similar age, have similar habits and similarly austere lifestyles, and even share the same dreams. This is according to David Bellos's The Novel of the Century: The Extraordinary Adventure of Les Misérables, which concludes Part Three with:

But Hugo put in a secret sign to remind himself and maybe those who knew him well that there were deep links of identity between the dutiful and persistent ex-convict and himself. Hugo was born on 26 February 1802, but because he was a slightly premature baby, he always believed he had been conceived on 24 June 1801. Valjean's prison number on his first incarceration at Toulon is 24601.
-- p. 162 (emphasis mine)

As a bonus, Valjean's second prisoner number was apparently also chosen for its special significance to Hugo: it refers to the month of his daughter Léopoldine's death. From footnote 46 in Kathryn Grossman's Figuring Transcendence in Les Miserables: Hugo's Romantic Sublime:

Gaudon demonstrates that this image, which represents genius in one of the poet's earliest carnets (8 July 1820), is a sign of his "deep identification" with Valjean (Temps 547). As further evidence that the hero is an alter ego, Gohin cites the two numbers assigned to him in prison. The first, 24601, refers to the supposed date of Hugo's conception (24 June 1801), while the second, 9430, alludes to Léopoldine's death in September 1843 ("Une histoire" 47; see also 52).
-- p. 165 (emphasis mine)
Answer: This is my personal interpretation.
24/06/1793 was the day of the Constitution of the Year I ("Acte constitutionnel du 24 juin 1793"), also know as the Montagnard  Constitution. The Montagnards was a political group of which Victor Hugo was an exponent.
The following years during the recurrence of this date people celebrated in a very participatory way and with great enthusiasm. So I believe a lot of people were conceived on those merry nights. Victor Hugo himself would certainly have been proud of it, being a Montagnard man. 24/06/1801, what a night!
Answer: 24th June is the nativity of John the Baptist.  24601 is the product of the 4th and 8th star numbers, 73 and 337. Hugo may have seen symbolism in this. I suggest we consider both as potential reasons for his choice.
Comment: Hi and welcome to Literature Stack Exchange. Are you aware of any evidence that Hugo was thinking of that specific birthday? Especially in the face of the other sources of inspiration?
Comment: For a start 'Jean' appears twice in his name.


How to add image in comment section?

Question: If I look at the help under comment section it mentioned ctrl+i will let me insert an image. It does not work for me.  What am I doing wrong?
Answer: You are too diligent :) and so read too much of the formatting help.  It starts with

Comments support only bold, italic, code and links; in addition, a few shorthand links are available.

Under this section, there is a hint: the above section is quoted for convenience from the full editing help, below. One gets this part on the top when coming from the comment help.
Images are for posts in any case, not for comments.  At the same time, interestingly enough, pressing Ctrli, I don't get the image snippet but the italic one.
There is a followup post now, by AndriyM: Wrong shortcut key information in Help Center
Comment: Pressing Ctrl+I doesn't bring the image insert box for me either. I think that's because the shortcut key for that action is actually Ctrl+G (but it won't work in a comment box).

How to add image in comment section?


Casting light on an object

Question: If I cast the light cantrip on an object and the object breaks while the spell is still in effect is each piece of the broken object still lit?  Could the pieces be carried in different directions?  Would the amount of light decrease based on the size of the piece?
Comment: Thanks. You're right. It has been answered. I didn't see that when I searched.
Comment: No problem! There's no penalty for unintentionally asking the same question again. In fact it's good: you get a quick answer, and now there's a higher chance that future searches will find this or that wording. Thank you for contributing!
Answer: The rules aren't specific enough for an accurate answer. I would not expect that each piece of the object would still emit light since that would allow you to break an item and use it as though you had dozens if not hundreds of light spells active. There are really only two light levels in this edition of D&D: bright and dim. You couldn't expect one large fragment to be him and a smaller fragment to be extra dim.
It would come down to the DM's decision. The two most likely results I would expect are:

The light spell ends since the object it was cast on no longer exists per se.
The largest fragment of the broken item continues to have the light spell active while the other fragments stop glowing.

Casting light on an object


Connecting 2 nodes

Question: Unable to connect 2 nodes ,it was working fine . When i run the admin.addPeer("enode info of the 2 node")
net.peerCount turns 1 for some time and returns 0 again .
Any idea whats going wrong ?
Answer: Give more details about your setup such as:

how are you launching the geth instances?
are you using the same block chain (genesis block and network id) for both?
are you running the private test net locally?
if yes, only one can use the default port (30303). How are you launching the second instance of geth?
are you using an IPv4 address such as 0.0.0.0? If yes change it to the loop back address (127.0.0.1) but not localhost. The same goes if it's an external address (do not use a domain name).
what does the geth console say when you add the peer?

Connecting 2 nodes


Why can Tobi not just use space-time ninjutsu to capture Bee and Naruto?

Question: Since Obito can travel through space-time, I wonder why he didn't just teleport to all those jinchuuriki? He could then easily bring them to an Akatsuki hideout where the combined force of them could capture them without others interfering.
Comment: He would have to know where exactly the Jinchuuriki are and have that place marked or else he wouldn't be able to teleport there.
Comment: Well, it would be a good start to teleport into their villages. Then the chances are high to find them there.
But what else besides the unknown whereabouts hinders him from doing so?
Comment: I get the feeling he could have, though it would have been very difficult since they are both very powerful and frequently under watch, especially in the village. He would be unable to restrain them since his genjutsu would not be very effective, so no matter what he would have a fight on his hands. His best hope would be when they are out of the village, but he has to find them first, and then be able to actually fight anyone guarding him as well.
Comment: @Ms.Steel Obito don't need to mark places to teleport. You're mistaking his jutsu with 4th Hokage's.
Comment: @AyaseEri maybe, but I'm pretty sure he even said he had to have the place marked or else he couldn't teleport there.
Comment: I believe it was he has to know the place before he can teleport to it.
Answer: The answer is because of the nature of his jutsu. His jutsu works by moving whole or part of his body into the other space. His jutsu has a weakness in that the bigger the object he is transporting, the longer the time needed for him to do it. This was noted by Konan and was mentioned during the fight between Konan and Tobi when the latter was about to retrieve the Rinnegan from Nagato's corpse. If I remember correctly, to move his entire body he needs about 5 seconds.
Now add another person to the equation and you get 10 whole seconds before he can do the jutsu successfully. 10 seconds next to a Jinchuuriki that knows you're going to kill him. There's no way they're just going to sit tight and enjoy the trip. So this makes kidnapping the Jinchuuriki and ganging up on them at the hideout like you're suggesting as an impossible thing to do.


Converting emissions readings between ppm and g/km

Question: Having taken my wife's 20 year old Nissan in for it's MOT test last week, I was looking at the results of the emissions test, and noticed that the Hydrocarbon reading was 6ppm - with a limit of 200. I was wondering how that compares to the more recent standards, but they're all measured in g/km - is there an easy way to convert between them?
Answer: Yes, there is a way, if the g/km is referring to hydrocarbons and not to CO2 (if it's referring to CO2 they are measuring different things).
You need to calculate how much exhaust gases the engine produces for one kilometer. You can do that based on fuel consumption because the amount of air going through the engine is dependent on the amount of fuel for stoichiometric gasoline engines. Then multiply the amount of exhaust gases by 6/(1000*1000), and you get the amount of hydrocarbons per km.
It ain't easy. I don't now have time to do example calculations here, but I'll see if I in the near future have time to do some example calculation. If I do, I'll edit and update my answer.
Comment: While this is simple math, the reality for sure is not that easy. The HC measurement is done at idle, maybe slightly increased rpm. The point is, emissions are quite bad at that condition, and are better at higher RPM and some load.  Just scaling the measured value by fuel consumption won't work.
Comment: Where I live, the HC measurement is at 2000 RPM, but there indeed is no engine load during the measurement, so the estimate would be very rough anyway, if using my method.
Answer: They are measuring two different things, so you can't convert them.
The MOT test results show how efficiently the engine is burning fuel - i.e. all the fuel that goes into the combustion chamber either gets burned, or decomposed in the catalytic converter.
The g/km numbers are effectively measuring fuel consumption, for the purpose of making the annual road tax less for "small cars" than for big ones. IMO that is just a political game, and increasing fuel tax by a small amount would be a fairer way to achieve the same thing - but the road haulage industry won't accept that idea, and it does have side effects for international road haulage where you can buy your fuel in the cheapest country but distribute your contribution to road maintenance costs where you drive, not where you paid the fuel tax.
It is also gamed by the car manufacturers. If a higher tax band starts at 140g CO2/km, there are a large number of car models which "officially" produce no more than 139. How very convenient, for marketing purposes - it eliminates the criterion as a factor in consumer choice.
A 50 cc motor scooter and a 5 liter stretch limo both have the same hydrocarbon limit on the emissions test, but obviously one produces much more CO2 per km travelled than the other.
Comment: Where I live, 50cc motor scooters have much less strict limits and no emission tests are done for them. The 5 liter stretch limo actually produces much less hydrocarbons, because the 50cc motor scooter probably has a two-stroke engine.


How can I determine storage directory from ADB?

Question: Is there a way I can use ADB to determine the external storage directory (equivalent of the Android API call Environment.getExternalStorageDirectory())?
Answer: adb shell echo $EXTERNAL_STORAGE.  All credit goes to Flow for leading me to experiment and find this.
Naturally you can use cd $EXTERNAL_STORAGE or whatever else you might need during an adb shell session or from a terminal emulator.
Comment: Good Teamwork :) +1
Comment: Very good! Thanks! Note, though, that if you may need to escape $ depending on your shell. example: adb shell echo \$EXTERNAL_STORAGE
Comment: Hmm, it turns out that my samsung vibrant gives me a different value for $EXTERNAL_STORAGE than it does Environment.getExternalStorageDirectory(). This isn't the first nasty bug I've found on this phone.
Comment: @stephelton That's disappointing.  Which one's incorrect?  $EXTERNAL_STORAGE is correct for me, `/mnt/sdcard/external_sd/`.
Answer: I don't think that this is possible. See Matthew's Post
But let's have a lock on how Environment.getExternalStorageDirectory() returns the external storage directory. A quick look in android/os/Environment.java shows that all this method does, is returning a static constant File member called EXTERNAL_STORAGE_DIRECTORY. This constant is initialized by
private static final File EXTERNAL_STORAGE_DIRECTORY
        = getDirectory("EXTERNAL_STORAGE", "/sdcard");

which calls getDirectory()
static File getDirectory(String variableName, String defaultPath) {
    String path = System.getenv(variableName);
    return path == null ? new File(defaultPath) : new File(path);
}

So the external storage directory is nothing else then an java System environment variable (or a predefined default). You could try to follow this trace further. Maybe the external storage directory is just a hard coded path in some configuration file on the filesystem. Or maybe there is a way to read out these environment variables via adb that I don't know.
Comment: I figured out the adb command using this info, +1.


Why can't we fully exploit the environment after the first episode in Q-learning?

Question: During the first episode, it's 100% exploration, because all our Q values are 0. Suppose we have 1000 time steps, and it's terminated by meeting a reward. So, after the first episode, why can't we make it 100% exploitation? Why do we still need exploration?
Answer: BlueTurtle's answer is good, but I'd like to add something.
Your question realistically has nothing to do with Q Learning, in fact, you can ask the same thing about just about any RL algorithm. In fact, even in multi-armed bandits, you can easily see why your proposed method is suboptimal (please don't interpret this as a criticism, because I think your question is a very natural one). My suggestion to you is to read up on multi-armed bandits since they're much simpler to analyze. I think even the Sutton and Barto book deals with your proposed method explicitly, and mathematically proves that other strategies are better.
Answer: You can't guarantee that you have taken every action from every state, even with  1000 time steps. There would be multiple outcomes:

The episode terminates, either by success or failure before the 1000
time steps. The agent is trying to maximise reward, if this is achieved by taking less than 1000 steps then it will do. It won't just walk around until it hits an arbitrary number of time steps.
If you have more states than time steps then you will
never be unable to visit all states and so you cannot guarantee that
the policy you followed was optimal (and hence would still want to explore). Even if you have #states = #time-steps then you will almost certaintly have more state-action pairs than timesteps. The only time this would be equal is if from every state there is only one action, which would be a trivial problem that wouldn't need RL to solve.
Comment: Ok this makes sense, it's more like since we're not sure it has taken every action possible from every state , we can't rely on the Q values as they might not be correct, ok suppose we do 2000 episodes or more, can we now make it 100% exploitation
Comment: Our estimated Q values will asymptotically approach the optimal Q values (Q^* in most textbooks) as the number of episodes approaches infinite. The exact number of episodes would be a function of the number of state-action pairs however, so we can not say conclusively if 2000 episodes would be enough.
Comment: We can decay the exploration rate (epsilon in most books) as the number of episodes increases though so after many thousands of episodes the probability of exploration is  neglible.
Comment: Oh okay, so everything is basically on saying we're not sure if 2000 episodes would be enough especially if the state space is large, but we've gotten better Q values on state action pairs so we can make y 90% exploitation and 10%exploration
Comment: Exactly but now think if you continue until 20,000 episodes, your Q values are becoming more accurate and you have explored more of the state space and know that certain state-action pairs are terrible so exploring them even more is pointless, so you reduce exploration to say 9% and so on.

If you have only been to a state a handful of times (especially if the resulting state is stochastic) you are unsure if it's a bad state - so you keep coming back. However, if you've been to a state 100 times and most of the time it sucked, you would be uninterested in going back.
Comment: On that makes sense, thank you, so if we're certain that the Q values have converged and are accurate,can we make it 100% exploitation or is there still a need of exploring


How to move file into virtual server

Question: I have a ESXi server with a Ubuntu server host running. I need to move a script file from my desktop where I manage the host and guest(with vSphere), to a directory on the guest server. Any suggestions on ways to do this?
Answer: Typically you'd use the same techniques that you would use if the guest was a physical server.  In this case scp via ssh.
Answer: scp would be the easiest and fastest solution if you are going to be sharing a lot of files regularly you can set up a SMB shared folder or a NFS, FTP server or whatever... But It's hard to think anything simpler than SCP.
I suppose the trick here would be thinking in your virtual server as a physic one that you can't access directly.
You can use a USB memory connect it to your computer and assign this resource to your server but why not SCP? :P
Answer: I actually recently looked into that and I wrote down (or gave links) how to do this for the various ESXi versions. See: https://serverfault.com/a/380925/106102
Basically as mrdenny suggested you just use ssh. It's not always on by default though. And if you copy your ssh key you will have to copy it again after the ESXi server reboots.

How to move file into virtual server


I accidentally hooked the negative side of the battery up firstand the wire running to the alternator started to smoke

Question: I accidentally hooked up negotiate cable to battery first causing the wire running to the alternator to smoke. I quickly unhooked it and hooked it up positive side first. But now my car won't stay running. It keeps stalling out on me as I'm driving. But it does slow first the lights will go then I have no power to nothing then the car dies. Then I jump it again with a jumper box and as long as that's hooked up I have power to everything except the radio because the fuse keeps popping on the wire running to the battery
Comment: Test the voltage rectifier by putting your meter on AC voltage on the battery, you shouldn't have more than .5 volts, if you have more than that, change the alternators rectifier, then put it on DC and you should have 13.2-15.1 volts, if you have more or less then your voltage rectifier needs replaced on your alternator
Comment: Hi David! Welcome to the site. Your question won't get much attention as it is written, though. Try rewording the title so people know straight away what they are dealing with. Something like "Car stalls after battery wire mixup" is possibly better.
Comment: I'm not sure how to edit the question on this site.
Comment: I would suggest that you have your battery and alternator tested and you also need to inspect the starter wire that was smoking to make sure it did not short out with any other wires nearby
Answer: When you mis-connect the battery cables the diodes in the alternator get fried. The battery may be servicable but the alternator must be replaced.
Answer: Connecting neg first then pos will not damage the system - it is accepted practice so that the final connection from a second battery can be made to the engine or chassis so if there is a small spark it is away from the battery that may be producing hydrogen. Yes, batteries do explode.
If you made the error of getting the leads on the wrong terminals then you may have damaged some electrical components which ones you have to chase down.
If it keeps stalling - have you properly recharged the original battery as some cars are really unhappy with a low battery voltage which causes lots of problems - spurious warnings lights for faults that don't exist etc
So, charge the battery thoroughly and see if the behavior improves...
Comment: When Solar Mike says charge the battery, he means Charge the battery, don't try to jump start a battery if it has less that 80% of a charge, you could be suffering from acid stratification and end up burning out one your cells in your battery, shaking the battery back and force might help stir up the H2SO4:H20 solution
Comment: The dash keeps showing-"check charging system". When I hooked the negative side up first and placed the positive side on that's when the wire running to the alternator started to smoke and smell really bad. I immediately disconnected the positive side and posts on the battery had melted in the middle. I then went and got another refurbished battery and hooked the new one up. But the wire running from the battery to the stero keeps blowing. It drove fine for about 15 minutes then while it was running I checked the battery voltage and that's when it read 9 and after that start stalling out jump
Comment: Battery. Just too make it home I had to leave the jumper boxed hooked to the battery and even then had No lights no power windows nothing worked.  Would it drive if the alternator was bad?