Categories/Search - Django Ecommerce Website - Htmx and Tailwind

In the fifth part of this tutorial series, we will show dynamic content in the sidebar of the shop. That means, we will get the categories from the database and list them there.

We will also make some changes, so that we can see which category is active.

Also, to make it easier for the users to find products, we are going to implement a simple search. In this search, we will be using a function from Django called Q. This makes it really easy to search in multiple fields at once.

Comments

EFSArCBy | Jul 02, 26 11:36

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

-1 OR 2+695-695-1=0+0+0+1 --

EFSArCBy | Jul 02, 26 11:38

-1 OR 2+864-864-1=0+0+0+1

EFSArCBy | Jul 02, 26 11:38

-1' OR 2+646-646-1=0+0+0+1 --

EFSArCBy | Jul 02, 26 11:38

-1' OR 2+629-629-1=0+0+0+1 or 'IqbH7Ev2'='

EFSArCBy | Jul 02, 26 11:38

-1" OR 2+656-656-1=0+0+0+1 --

EFSArCBy | Jul 02, 26 11:38

555*if(now()=sysdate(),sleep(15),0)

EFSArCBy | Jul 02, 26 11:38

5550'XOR(555*if(now()=sysdate(),sleep(15),0))XOR'Z

EFSArCBy | Jul 02, 26 11:38

5550"XOR(555*if(now()=sysdate(),sleep(15),0))XOR"Z

EFSArCBy | Jul 02, 26 11:38

(select(0)from(select(sleep(15)))v)/*'+(select(0)from(select(sleep(15)))v)+'"+(select(0)from(select(sleep(15)))v)+"*/

EFSArCBy | Jul 02, 26 11:38

555-1; waitfor delay '0:0:15' --

EFSArCBy | Jul 02, 26 11:38

555-1); waitfor delay '0:0:15' --

EFSArCBy | Jul 02, 26 11:38

555-1 waitfor delay '0:0:15' --

EFSArCBy | Jul 02, 26 11:38

555jQ9iVBN7'; waitfor delay '0:0:15' --

EFSArCBy | Jul 02, 26 11:38

555-1 OR 462=(SELECT 462 FROM PG_SLEEP(15))--

EFSArCBy | Jul 02, 26 11:38

555-1) OR 720=(SELECT 720 FROM PG_SLEEP(15))--

EFSArCBy | Jul 02, 26 11:38

555-1)) OR 927=(SELECT 927 FROM PG_SLEEP(15))--

EFSArCBy | Jul 02, 26 11:38

555NsCIFNQF' OR 48=(SELECT 48 FROM PG_SLEEP(15))--

EFSArCBy | Jul 02, 26 11:38

555IqST89M7') OR 633=(SELECT 633 FROM PG_SLEEP(15))--

EFSArCBy | Jul 02, 26 11:38

55590etf4jn')) OR 487=(SELECT 487 FROM PG_SLEEP(15))--

EFSArCBy | Jul 02, 26 11:38

555*DBMS_PIPE.RECEIVE_MESSAGE(CHR(99)||CHR(99)||CHR(99),15)

EFSArCBy | Jul 02, 26 11:38

555'||DBMS_PIPE.RECEIVE_MESSAGE(CHR(98)||CHR(98)||CHR(98),15)||'

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555'"

EFSArCBy | Jul 02, 26 11:38

@@yeopu

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

-1 OR 2+504-504-1=0+0+0+1 -- | Jul 02, 26 11:38

555

-1 OR 2+415-415-1=0+0+0+1 | Jul 02, 26 11:38

555

-1' OR 2+822-822-1=0+0+0+1 -- | Jul 02, 26 11:38

555

-1' OR 2+846-846-1=0+0+0+1 or '9XEy07it'=' | Jul 02, 26 11:38

555

-1" OR 2+237-237-1=0+0+0+1 -- | Jul 02, 26 11:38

555

if(now()=sysdate(),sleep(15),0) | Jul 02, 26 11:38

555

EFSArCBy0'XOR(if(now()=sysdate(),sleep(15),0))XOR'Z | Jul 02, 26 11:38

555

EFSArCBy0"XOR(if(now()=sysdate(),sleep(15),0))XOR"Z | Jul 02, 26 11:38

555

EFSArCBy-1 waitfor delay '0:0:15' -- | Jul 02, 26 11:38

555

EFSArCByMKxJbuDa'; waitfor delay '0:0:15' -- | Jul 02, 26 11:38

555

EFSArCBy3TFYcMV3' OR 946=(SELECT 946 FROM PG_SLEEP(15))-- | Jul 02, 26 11:38

555

EFSArCBypa6Ms8Km') OR 519=(SELECT 519 FROM PG_SLEEP(15))-- | Jul 02, 26 11:38

555

EFSArCByccO5JlE5')) OR 594=(SELECT 594 FROM PG_SLEEP(15))-- | Jul 02, 26 11:38

555

EFSArCBy'||DBMS_PIPE.RECEIVE_MESSAGE(CHR(98)||CHR(98)||CHR(98),15)||' | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy'" | Jul 02, 26 11:38

555

@@UKmvE | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 02, 26 11:38

555

EFSArCBy | Jul 21, 26 12:32

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

-1 OR 2+419-419-1=0+0+0+1 --

EFSArCBy | Jul 21, 26 12:34

-1 OR 2+500-500-1=0+0+0+1

EFSArCBy | Jul 21, 26 12:34

-1' OR 2+940-940-1=0+0+0+1 --

EFSArCBy | Jul 21, 26 12:34

-1' OR 2+859-859-1=0+0+0+1 or 'WN8z7a6x'='

EFSArCBy | Jul 21, 26 12:34

-1" OR 2+668-668-1=0+0+0+1 --

EFSArCBy | Jul 21, 26 12:34

555*if(now()=sysdate(),sleep(15),0)

EFSArCBy | Jul 21, 26 12:34

5550'XOR(555*if(now()=sysdate(),sleep(15),0))XOR'Z

EFSArCBy | Jul 21, 26 12:34

5550"XOR(555*if(now()=sysdate(),sleep(15),0))XOR"Z

EFSArCBy | Jul 21, 26 12:34

(select(0)from(select(sleep(15)))v)/*'+(select(0)from(select(sleep(15)))v)+'"+(select(0)from(select(sleep(15)))v)+"*/

EFSArCBy | Jul 21, 26 12:34

555-1; waitfor delay '0:0:15' --

EFSArCBy | Jul 21, 26 12:34

555-1); waitfor delay '0:0:15' --

EFSArCBy | Jul 21, 26 12:34

555-1 waitfor delay '0:0:15' --

EFSArCBy | Jul 21, 26 12:34

555RvOoYcSa'; waitfor delay '0:0:15' --

EFSArCBy | Jul 21, 26 12:34

555-1 OR 490=(SELECT 490 FROM PG_SLEEP(15))--

EFSArCBy | Jul 21, 26 12:34

555-1) OR 874=(SELECT 874 FROM PG_SLEEP(15))--

EFSArCBy | Jul 21, 26 12:34

555-1)) OR 244=(SELECT 244 FROM PG_SLEEP(15))--

EFSArCBy | Jul 21, 26 12:34

555X5GebQfC' OR 529=(SELECT 529 FROM PG_SLEEP(15))--

EFSArCBy | Jul 21, 26 12:34

555DATuPF8v') OR 958=(SELECT 958 FROM PG_SLEEP(15))--

EFSArCBy | Jul 21, 26 12:34

555PLIm7Obl')) OR 54=(SELECT 54 FROM PG_SLEEP(15))--

EFSArCBy | Jul 21, 26 12:34

555*DBMS_PIPE.RECEIVE_MESSAGE(CHR(99)||CHR(99)||CHR(99),15)

EFSArCBy | Jul 21, 26 12:34

555'||DBMS_PIPE.RECEIVE_MESSAGE(CHR(98)||CHR(98)||CHR(98),15)||'

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555'"

EFSArCBy | Jul 21, 26 12:34

@@HrDSW

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

-1 OR 2+228-228-1=0+0+0+1 -- | Jul 21, 26 12:34

555

-1 OR 2+823-823-1=0+0+0+1 | Jul 21, 26 12:34

555

-1' OR 2+443-443-1=0+0+0+1 -- | Jul 21, 26 12:34

555

-1' OR 2+567-567-1=0+0+0+1 or 'kkHikVt3'=' | Jul 21, 26 12:34

555

-1" OR 2+785-785-1=0+0+0+1 -- | Jul 21, 26 12:34

555

if(now()=sysdate(),sleep(15),0) | Jul 21, 26 12:34

555

EFSArCBy0'XOR(if(now()=sysdate(),sleep(15),0))XOR'Z | Jul 21, 26 12:34

555

EFSArCBy0"XOR(if(now()=sysdate(),sleep(15),0))XOR"Z | Jul 21, 26 12:34

555

EFSArCBy-1 waitfor delay '0:0:15' -- | Jul 21, 26 12:34

555

EFSArCBy6mS8rb3T'; waitfor delay '0:0:15' -- | Jul 21, 26 12:34

555

EFSArCByLVRFlch4' OR 815=(SELECT 815 FROM PG_SLEEP(15))-- | Jul 21, 26 12:34

555

EFSArCBy0vss5zrL') OR 341=(SELECT 341 FROM PG_SLEEP(15))-- | Jul 21, 26 12:34

555

EFSArCByBdWJqPcu')) OR 527=(SELECT 527 FROM PG_SLEEP(15))-- | Jul 21, 26 12:34

555

EFSArCBy'||DBMS_PIPE.RECEIVE_MESSAGE(CHR(98)||CHR(98)||CHR(98),15)||' | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy'" | Jul 21, 26 12:34

555

@@5IdRF | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 21, 26 12:34

555

EFSArCBy | Jul 23, 26 03:28

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

-1 OR 2+128-128-1=0+0+0+1 --

EFSArCBy | Jul 23, 26 03:30

-1 OR 2+888-888-1=0+0+0+1

EFSArCBy | Jul 23, 26 03:30

-1' OR 2+130-130-1=0+0+0+1 --

EFSArCBy | Jul 23, 26 03:30

-1' OR 2+764-764-1=0+0+0+1 or '3xG8I9Y1'='

EFSArCBy | Jul 23, 26 03:30

-1" OR 2+537-537-1=0+0+0+1 --

EFSArCBy | Jul 23, 26 03:30

555*if(now()=sysdate(),sleep(15),0)

EFSArCBy | Jul 23, 26 03:30

5550'XOR(555*if(now()=sysdate(),sleep(15),0))XOR'Z

EFSArCBy | Jul 23, 26 03:30

5550"XOR(555*if(now()=sysdate(),sleep(15),0))XOR"Z

EFSArCBy | Jul 23, 26 03:30

(select(0)from(select(sleep(15)))v)/*'+(select(0)from(select(sleep(15)))v)+'"+(select(0)from(select(sleep(15)))v)+"*/

EFSArCBy | Jul 23, 26 03:30

555-1; waitfor delay '0:0:15' --

EFSArCBy | Jul 23, 26 03:30

555-1); waitfor delay '0:0:15' --

EFSArCBy | Jul 23, 26 03:30

555-1 waitfor delay '0:0:15' --

EFSArCBy | Jul 23, 26 03:30

555Ih3Uqx8B'; waitfor delay '0:0:15' --

EFSArCBy | Jul 23, 26 03:30

555-1 OR 132=(SELECT 132 FROM PG_SLEEP(15))--

EFSArCBy | Jul 23, 26 03:30

555-1) OR 777=(SELECT 777 FROM PG_SLEEP(15))--

EFSArCBy | Jul 23, 26 03:30

555-1)) OR 303=(SELECT 303 FROM PG_SLEEP(15))--

EFSArCBy | Jul 23, 26 03:30

555en4Ocx5w' OR 439=(SELECT 439 FROM PG_SLEEP(15))--

EFSArCBy | Jul 23, 26 03:30

555LGDMkJrm') OR 235=(SELECT 235 FROM PG_SLEEP(15))--

EFSArCBy | Jul 23, 26 03:30

555viW0tAYn')) OR 651=(SELECT 651 FROM PG_SLEEP(15))--

EFSArCBy | Jul 23, 26 03:30

555*DBMS_PIPE.RECEIVE_MESSAGE(CHR(99)||CHR(99)||CHR(99),15)

EFSArCBy | Jul 23, 26 03:30

555'||DBMS_PIPE.RECEIVE_MESSAGE(CHR(98)||CHR(98)||CHR(98),15)||'

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555'"

EFSArCBy | Jul 23, 26 03:30

@@rs4F1

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

-1 OR 2+274-274-1=0+0+0+1 -- | Jul 23, 26 03:30

555

-1 OR 2+398-398-1=0+0+0+1 | Jul 23, 26 03:30

555

-1' OR 2+760-760-1=0+0+0+1 -- | Jul 23, 26 03:30

555

-1' OR 2+985-985-1=0+0+0+1 or 'TELN65eO'=' | Jul 23, 26 03:30

555

-1" OR 2+278-278-1=0+0+0+1 -- | Jul 23, 26 03:30

555

if(now()=sysdate(),sleep(15),0) | Jul 23, 26 03:30

555

EFSArCBy0'XOR(if(now()=sysdate(),sleep(15),0))XOR'Z | Jul 23, 26 03:30

555

EFSArCBy0"XOR(if(now()=sysdate(),sleep(15),0))XOR"Z | Jul 23, 26 03:30

555

EFSArCBy-1 waitfor delay '0:0:15' -- | Jul 23, 26 03:30

555

EFSArCBy6rUhC7Rd'; waitfor delay '0:0:15' -- | Jul 23, 26 03:30

555

EFSArCByLGZkb5xL' OR 423=(SELECT 423 FROM PG_SLEEP(15))-- | Jul 23, 26 03:30

555

EFSArCBy2bzy27FN') OR 399=(SELECT 399 FROM PG_SLEEP(15))-- | Jul 23, 26 03:30

555

EFSArCByQ1RtB5jG')) OR 779=(SELECT 779 FROM PG_SLEEP(15))-- | Jul 23, 26 03:30

555

EFSArCBy'||DBMS_PIPE.RECEIVE_MESSAGE(CHR(98)||CHR(98)||CHR(98),15)||' | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy'" | Jul 23, 26 03:30

555

@@nuXeD | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

EFSArCBy | Jul 23, 26 03:30

555

Add comment

Info

Please log in to comment!

Newsletter

Subscribe to my weekly newsletter. One time per week I will send you a short summary of the tutorials I have posted in the past week.