# programming

**URL:** https://forum.kirupa.com/c/programming/41.md?page=35

[Latest](https://forum.kirupa.com/latest.md) · [Categories](https://forum.kirupa.com/categories.md)

**Page:** 36

---

## [Classes and a strange property](https://forum.kirupa.com/t/classes-and-a-strange-property/646970)

<div class="topic-metadata">

**Author:** [@Belfry777](https://forum.kirupa.com/u/Belfry777)\
**Replies:** 1\
**Last updated:** [April 1, 2021, 12:46am UTC](https://forum.kirupa.com/t/classes-and-a-strange-property/646970 "2021-04-01T00:46:35Z")

</div>

Hi there, From following chapter 20 on classes, I have run into a strange situation. Here is the code: class Planet { constructor(name, radius) { this.name = name; this.radius = radius; } getSurfaceAre…

---

## [Regular expression to build 2D array-java](https://forum.kirupa.com/t/regular-expression-to-build-2d-array-java/646874)

<div class="topic-metadata">

**Author:** [@Umair\_Ashraf](https://forum.kirupa.com/u/Umair_Ashraf)\
**Replies:** 0\
**Last updated:** [March 27, 2021, 11:17pm UTC](https://forum.kirupa.com/t/regular-expression-to-build-2d-array-java/646874 "2021-03-27T23:17:27Z")

</div>

I am struggling to form the regex expression from the below String Array notes. I have tried to use few things below but I am not getting what I am expecting, like from notes\[0\] I am only expecting 10.0 and higher, Wher…

---

## [Need a help in making a website SEO friendly!](https://forum.kirupa.com/t/need-a-help-in-making-a-website-seo-friendly/646870)

<div class="topic-metadata">

**Author:** [@Juliemartin150](https://forum.kirupa.com/u/Juliemartin150)\
**Replies:** 2\
**Last updated:** [March 27, 2021, 1:06pm UTC](https://forum.kirupa.com/t/need-a-help-in-making-a-website-seo-friendly/646870 "2021-03-27T13:06:54Z")

</div>

We have a custom logo website. Initially, it was an idea of me and my friend, and my friend designed the site himself. But now we are facing a lot of problems, few pages are not working properly and even after so many ef…

---

## [How to code falling stars?](https://forum.kirupa.com/t/how-to-code-falling-stars/646243)

<div class="topic-metadata">

**Author:** [@Marik\_Gaming](https://forum.kirupa.com/u/Marik_Gaming)\
**Replies:** 17\
**Last updated:** [March 26, 2021, 4:41am UTC](https://forum.kirupa.com/t/how-to-code-falling-stars/646243 "2021-03-26T04:41:02Z")

</div>

Hello, I have found this webpage where the code for falling snow is. Is there anyone who can tell me how I can change it to stars instead of snow? Thank you very much

---

## [Do we need the keyword "this"?](https://forum.kirupa.com/t/do-we-need-the-keyword-this/646806)

<div class="topic-metadata">

**Author:** [@Belfry777](https://forum.kirupa.com/u/Belfry777)\
**Replies:** 3\
**Last updated:** [March 25, 2021, 10:35am UTC](https://forum.kirupa.com/t/do-we-need-the-keyword-this/646806 "2021-03-25T10:35:55Z")

</div>

Hi, As some you know, I am trying to learn JavaScript from the book… In a chapter, there is this example: let person = { getName: function () { return "The Name is " + this.firs…

---

## [How can we access wordpress admin?](https://forum.kirupa.com/t/how-can-we-access-wordpress-admin/640315)

<div class="topic-metadata">

**Author:** [@teqizer](https://forum.kirupa.com/u/teqizer)\
**Replies:** 2\
**Last updated:** [March 25, 2021, 5:32am UTC](https://forum.kirupa.com/t/how-can-we-access-wordpress-admin/640315 "2021-03-25T05:32:54Z")

</div>

I can’t access my wp-admin. how can I go to the admin dashboard.

---

## [JavaScript Object Inheritence, new() and prototype](https://forum.kirupa.com/t/javascript-object-inheritence-new-and-prototype/646731)

<div class="topic-metadata">

**Author:** [@Belfry777](https://forum.kirupa.com/u/Belfry777)\
**Replies:** 6\
**Last updated:** [March 23, 2021, 11:48pm UTC](https://forum.kirupa.com/t/javascript-object-inheritence-new-and-prototype/646731 "2021-03-23T23:48:40Z")

</div>

Hello, After working in the book by Kirupa, I have a few questions about the Website Link listed at the end of the chapter (see the bottom part about constructor functions). Firstly, I do not understand what new() does…

---

## [Reading NDJSON stream in the browser](https://forum.kirupa.com/t/reading-ndjson-stream-in-the-browser/646715)

<div class="topic-metadata">

**Author:** [@steve.mills](https://forum.kirupa.com/u/steve.mills)\
**Replies:** 0\
**Last updated:** [March 21, 2021, 2:28am UTC](https://forum.kirupa.com/t/reading-ndjson-stream-in-the-browser/646715 "2021-03-21T02:28:03Z")

</div>

I recently was trying to stream some NDJSON to a service worker and also into a comment feed. It was a bit of an issue finding just a NDJSON reader as anything I could find was a reader → new readableStream pipe. (retur…

---

## [The example from chapter 15 of the book "Learning React" 2nd edition does not work as planned](https://forum.kirupa.com/t/the-example-from-chapter-15-of-the-book-learning-react-2nd-edition-does-not-work-as-planned/646631)

<div class="topic-metadata">

**Author:** [@11133](https://forum.kirupa.com/u/11133)\
**Replies:** 3\
**Last updated:** [March 20, 2021, 11:12pm UTC](https://forum.kirupa.com/t/the-example-from-chapter-15-of-the-book-learning-react-2nd-edition-does-not-work-as-planned/646631 "2021-03-20T23:12:20Z")

</div>

Hi, Kirupa! I express my gratitude for the book “Learning React” 2nd edition! It really helps in quickly and easily learning the React library. When you run the example in Chapter 15, the code does not work as expected. …

---

## [Using codepen.io as a testbed](https://forum.kirupa.com/t/using-codepen-io-as-a-testbed/646694)

<div class="topic-metadata">

**Author:** [@karlar](https://forum.kirupa.com/u/karlar)\
**Replies:** 1\
**Last updated:** [March 20, 2021, 11:10pm UTC](https://forum.kirupa.com/t/using-codepen-io-as-a-testbed/646694 "2021-03-20T23:10:00Z")

</div>

I am trying to complete Chapter 4 in Learning React… I have seen the errata and have another issue. I am only seeing plain, unformatted text in the output. I am using codepen.io as my development platform and have ente…

---

## [Scanning QR codes from camera livestream (camera stream embedded in HTML page)](https://forum.kirupa.com/t/scanning-qr-codes-from-camera-livestream-camera-stream-embedded-in-html-page/646636)

<div class="topic-metadata">

**Author:** [@Fejiro\_Eruotor](https://forum.kirupa.com/u/Fejiro_Eruotor)\
**Replies:** 0\
**Last updated:** [March 17, 2021, 2:02am UTC](https://forum.kirupa.com/t/scanning-qr-codes-from-camera-livestream-camera-stream-embedded-in-html-page/646636 "2021-03-17T02:02:03Z")

</div>

Hello Fellow Devs, I recently came across a related article while trying to figure out QR scanning for my desktop app. My code is as it is on the quoted article below; Article on adding to Camera live stream to your HT…

---

## [? order of execution / or who done what to whom and when ?](https://forum.kirupa.com/t/order-of-execution-or-who-done-what-to-whom-and-when/646505)

<div class="topic-metadata">

**Author:** [@vmars316](https://forum.kirupa.com/u/vmars316)\
**Replies:** 4\
**Last updated:** [March 15, 2021, 7:08am UTC](https://forum.kirupa.com/t/order-of-execution-or-who-done-what-to-whom-and-when/646505 "2021-03-15T07:08:02Z")

</div>

Hello , I am having trouble with promises , or who done what to whom and when ? Pls , what is the order of execution with the following code: const wait = time =\> new Promise((resolve) =\> setTImeout(resolve, time)) ;…

---

## [undefined issue with looping arrays?](https://forum.kirupa.com/t/undefined-issue-with-looping-arrays/646582)

<div class="topic-metadata">

**Author:** [@HammerDown](https://forum.kirupa.com/u/HammerDown)\
**Replies:** 4\
**Last updated:** [March 14, 2021, 8:45pm UTC](https://forum.kirupa.com/t/undefined-issue-with-looping-arrays/646582 "2021-03-14T20:45:54Z")

</div>

Just getting my feet wet in Development. I already see frustration setting in but will not give up easily. I want to learn. Have a few projects that I am doing for a boot camp. Could use veteran eyes and see why it is c…

---

## [React.js](https://forum.kirupa.com/t/react-js/646570)

<div class="topic-metadata">

**Author:** [@Ferhad\_Kerimli](https://forum.kirupa.com/u/Ferhad_Kerimli)\
**Replies:** 0\
**Last updated:** [March 13, 2021, 8:39am UTC](https://forum.kirupa.com/t/react-js/646570 "2021-03-13T08:39:49Z")

</div>

Hello , i hope you doing well. i have question regarding React Router. The below , MainPAgeContainer compenent did not show on display. Header and Search is displaying MainPageContainer not. Could you tell me please t…

---

## [The Ken Burns Effect | Frontend Coding Exercises](https://forum.kirupa.com/t/the-ken-burns-effect-frontend-coding-exercises/633786)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 7\
**Last updated:** [March 4, 2021, 5:35am UTC](https://forum.kirupa.com/t/the-ken-burns-effect-frontend-coding-exercises/633786 "2021-03-04T05:35:03Z")

</div>

by kirupa | 18 September 2015 Ken Burns is a pretty famous (and award-winning) documentary film maker. While I haven't personally seen any of his documentaries, it's not cool to admit that publically. If you hav…

---

## [Code design: anchoring sidebar components](https://forum.kirupa.com/t/code-design-anchoring-sidebar-components/645106)

<div class="topic-metadata">

**Author:** [@vayu251](https://forum.kirupa.com/u/vayu251)\
**Replies:** 3\
**Last updated:** [March 3, 2021, 7:27pm UTC](https://forum.kirupa.com/t/code-design-anchoring-sidebar-components/645106 "2021-03-03T19:27:16Z")

</div>

I am working on building a site for a “virtual comic book” in react. For context, I’m very new to web dev (I just finished working through Kirupa’s react book), so the entire website is just various instances of the div…

---

## [A form calculating the price from the required fields, plus optional fields](https://forum.kirupa.com/t/a-form-calculating-the-price-from-the-required-fields-plus-optional-fields/646365)

<div class="topic-metadata">

**Author:** [@Mary\_Pieroszkiewicz](https://forum.kirupa.com/u/Mary_Pieroszkiewicz)\
**Replies:** 1\
**Last updated:** [March 3, 2021, 4:59am UTC](https://forum.kirupa.com/t/a-form-calculating-the-price-from-the-required-fields-plus-optional-fields/646365 "2021-03-03T04:59:14Z")

</div>

For now, I have set up all the input of the form to enter a value to calculate the price, now a change is needed, there are fields that are not required to calculate the price from the required fields, and now how to do …

---

## [Disabling Form Autocompletion](https://forum.kirupa.com/t/disabling-form-autocompletion/646060)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 2\
**Last updated:** [February 13, 2021, 1:23am UTC](https://forum.kirupa.com/t/disabling-form-autocompletion/646060 "2021-02-13T01:23:44Z")

</div>

This is a companion discussion topic for the original entry at https://www.kirupa.com/html5/disable\_form\_autocomplete.htm

---

## [Mapping, Filtering, and Reducing Things in an Array](https://forum.kirupa.com/t/mapping-filtering-and-reducing-things-in-an-array/637057)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 4\
**Last updated:** [February 8, 2021, 5:42pm UTC](https://forum.kirupa.com/t/mapping-filtering-and-reducing-things-in-an-array/637057 "2021-02-08T17:42:02Z")

</div>

This is the happening place to discuss what is going on with \`map\`, \`filter\`, and \`reduce\`: http://www.kirupa.com/html5/arrays\_map\_filter\_reduce.htm :slight\_smile:

---

## [Sumac Sequence Calculator](https://forum.kirupa.com/t/sumac-sequence-calculator/645957)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 0\
**Last updated:** [February 2, 2021, 6:05am UTC](https://forum.kirupa.com/t/sumac-sequence-calculator/645957 "2021-02-02T06:05:49Z")

</div>

I randomly stumbled upon this Sumac Sequence challenge, and while I wasn’t interested in coming up with the most compact solution, it was something that I wanted to build a readable solution and tutorial around! See it …

---

## [Inline template diffing vanilla JS](https://forum.kirupa.com/t/inline-template-diffing-vanilla-js/645924)

<div class="topic-metadata">

**Author:** [@steve.mills](https://forum.kirupa.com/u/steve.mills)\
**Replies:** 2\
**Last updated:** [February 2, 2021, 5:27am UTC](https://forum.kirupa.com/t/inline-template-diffing-vanilla-js/645924 "2021-02-02T05:27:49Z")

</div>

Hey guys, Just curious, does anybody know of a better way of diffing an inline template? I have tried using the HTML template instead of script type = ‘text/template’ but the innerHTML.toString() causes it to be 30-40%…

---

## [I want to get two seperate instances of cursor values in my clientX/Y; method in JavaScript](https://forum.kirupa.com/t/i-want-to-get-two-seperate-instances-of-cursor-values-in-my-clientx-y-method-in-javascript/645929)

<div class="topic-metadata">

**Author:** [@Fejiro\_Eruotor](https://forum.kirupa.com/u/Fejiro_Eruotor)\
**Replies:** 3\
**Last updated:** [February 1, 2021, 6:08pm UTC](https://forum.kirupa.com/t/i-want-to-get-two-seperate-instances-of-cursor-values-in-my-clientx-y-method-in-javascript/645929 "2021-02-01T18:08:19Z")

</div>

Hey, So i have this challenge with my code. I want it to store the cursor values after mouse event is triggered. Here is my JS code trying to have two sets of cursor values stored; \<script\> function RHS(){ var e = wi…

---

## [Has swift outpaced Objective-C on iOS?](https://forum.kirupa.com/t/has-swift-outpaced-objective-c-on-ios/645904)

<div class="topic-metadata">

**Author:** [@tbo](https://forum.kirupa.com/u/tbo)\
**Replies:** 3\
**Last updated:** [January 30, 2021, 7:31pm UTC](https://forum.kirupa.com/t/has-swift-outpaced-objective-c-on-ios/645904 "2021-01-30T19:31:20Z")

</div>

Is swift now regarded as the preferred option over Objective-C on iOS? Im not sure if there’s any concrete data public but just curious

---

## [My request for data from server using the XMLHttpRequest, keeps returning undefined](https://forum.kirupa.com/t/my-request-for-data-from-server-using-the-xmlhttprequest-keeps-returning-undefined/645880)

<div class="topic-metadata">

**Author:** [@seunawonugba](https://forum.kirupa.com/u/seunawonugba)\
**Replies:** 5\
**Last updated:** [January 30, 2021, 2:12am UTC](https://forum.kirupa.com/t/my-request-for-data-from-server-using-the-xmlhttprequest-keeps-returning-undefined/645880 "2021-01-30T02:12:59Z")

</div>

I tried to request data from this server address https://codexpression.github.io/catz/catz.json using AJAX XMLHttpRequest, but when I tried to console.log the property value of the text, I keep getting “undefined”, plea…

---

## [Running Your Code at the Right Time](https://forum.kirupa.com/t/running-your-code-at-the-right-time/352075)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 5\
**Last updated:** [January 29, 2021, 6:12am UTC](https://forum.kirupa.com/t/running-your-code-at-the-right-time/352075 "2021-01-29T06:12:50Z")

</div>

Run your code at the right time by making sense of DOMContentLoaded, load, async, defer, and position in the DOM! This is a companion discussion topic for the original entry at http://www.kirupa.com/html5/running\_your\_…

---

## [Playing Sounds Using the Audio Element](https://forum.kirupa.com/t/playing-sounds-using-the-audio-element/645727)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 0\
**Last updated:** [January 18, 2021, 1:14am UTC](https://forum.kirupa.com/t/playing-sounds-using-the-audio-element/645727 "2021-01-18T01:14:44Z")

</div>

This is a companion discussion topic for the original entry at https://www.kirupa.com/html5/playing\_sound\_audio\_element.htm

---

## [Loading Script Files Dynamically](https://forum.kirupa.com/t/loading-script-files-dynamically/641761)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 12\
**Last updated:** [January 15, 2021, 12:13pm UTC](https://forum.kirupa.com/t/loading-script-files-dynamically/641761 "2021-01-15T12:13:50Z")

</div>

This is a companion discussion topic for the original entry at https://www.kirupa.com/html5/loading\_script\_files\_dynamically.htm

---

## [Add Webcam in a text chat](https://forum.kirupa.com/t/add-webcam-in-a-text-chat/645705)

<div class="topic-metadata">

**Author:** [@ionicdev](https://forum.kirupa.com/u/ionicdev)\
**Replies:** 0\
**Last updated:** [January 14, 2021, 10:51am UTC](https://forum.kirupa.com/t/add-webcam-in-a-text-chat/645705 "2021-01-14T10:51:39Z")

</div>

Hello guys, i’ve a problem, i’ve read so much tutorial like kirupa webrtc peertopeer webcam call but anything solve my questions i’ve a text chat multiuser i need to add to everyone a button for enable own cam and when…

---

## [TinaCMS](https://forum.kirupa.com/t/tinacms/645649)

<div class="topic-metadata">

**Author:** [@travis](https://forum.kirupa.com/u/travis)\
**Replies:** 2\
**Last updated:** [January 11, 2021, 10:17pm UTC](https://forum.kirupa.com/t/tinacms/645649 "2021-01-11T22:17:30Z")

</div>

Has anyone used This Is Not A CMS (Tina CMS)? I used it recently with a NextJS project and man is it a pleasure to use! It’s smooth as butter and adds a really nice client frontend for seamless editing of a website but …

---

## [Removing Duplicate Arrays from an Array of Arrays](https://forum.kirupa.com/t/removing-duplicate-arrays-from-an-array-of-arrays/641147)

<div class="topic-metadata">

**Author:** [@kirupa](https://forum.kirupa.com/u/kirupa)\
**Replies:** 7\
**Last updated:** [January 11, 2021, 6:48pm UTC](https://forum.kirupa.com/t/removing-duplicate-arrays-from-an-array-of-arrays/641147 "2021-01-11T18:48:45Z")

</div>

In the Useful Array Tricks article, one of the tricks described how to ensure the contents of our array are unique and no duplicate items exist. The technique described really only worked when the array items in questio…

[Previous page](https://forum.kirupa.com/c/programming/41.md?page=34)

[Next page](https://forum.kirupa.com/c/programming/41.md?page=36)
